This PR can be significantly simplified by making the `day` and `id` optional in this url.
Something like `url(r'^(?P<year>\d+)/(?P<month>\w+)(?:/(?P<day>\d+)/(?P<id>\d+))?/$',`. By doing this all you need next, is to add the two lines in `redirect_legacy_reports` in the `view_ng_report` view with a conditional to check if the day and id are None.