Skip to content

Conversation

wynnw
Copy link

@wynnw wynnw commented Nov 12, 2019

  • This prevents a crash if the dmp_path regex captures a None value for
    the dmp_urlparams matching group. A regex like:

^(org.(?P[_a-zA-Z0-9-]+)/)?(?P<dmp_page>[_a-zA-Z0-9-]+)(.?P<dmp_function>[_a-zA-Z0-9.-]+)?/(?P<dmp_urlparams>.+?)?$

for a path like:
org.agency-1/agent_dashboard/

would result in the crash.

Wynn Wilkes added 2 commits November 12, 2019 10:21
- This prevents a crash if the dmp_path regex captures a None value for
the dmp_urlparams matching group. A regex like:

^(org\.(?P<orgslug>[_a-zA-Z0-9\-]+)/)?(?P<dmp_page>[_a-zA-Z0-9\-]+)(\.?P<dmp_function>[_a-zA-Z0-9\.\-]+)?/(?P<dmp_urlparams>.+?)?$

for a path like:
org.agency-1/agent_dashboard/

would result in the crash.
- This avoids silent errors when a view has a syntax error or other
failure that causes it to not import.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant