-
Notifications
You must be signed in to change notification settings - Fork 126
Description
So right now there are actually three ways to set up redirects on CF.gov (I'm ignoring the urls.py
approach that came up in a recent issue/PR because it shouldn't actually be used for this reason):
- Wagtail administration for one-off static redirects
redirects.conf
for RegEx/wildcard-based redirects- Wagtail redirects set up specifically for Ask CFPB
The third category is weird and causes a number of reporting or functionality issues:
- These redirects do not show up in our standard redirects export, making them hard to track and cross-reference with our larger set of redirects
- Though the Ask CFPB data export does include these redirects, it does so in an odd, indirect way that requires several additional steps to properly render in the same manner as our usual redirects report
- I think Wagtail is treating pages redirected in this category as still existing/live on the website, which leads to some odd issues including, among other things, the existence of duplicate/redirected URLs in our sitemap.xml file
I do not know why the Ask section originally had redirects set up uniquely in this way -- probably to let content managers who were handling those pages set up redirects without having to interact with the Admin panel areas -- but I think it's at best duplicative and unnecessary now, and at worst actively causes confusion and harm to the site structure and ability to report on and maintain Ask CPFB over time.
Using the Ask CFPB export data, I've created a redirects CSV that can be mass-imported into Wagtail. (The total count is 357 redirects set up this way, including English and Spanish) Before I commit to doing that, though, I want to understand where there are any legitimate use-cases for keeping Ask redirects as-is and, if not, what the technical lift would be to remove that field/functionality entirely from those page types.