Background:
Double redirects are a problem on wikis that don't have bots that will automatically fix them. The big WMF wikis all have bots, but remember that MediaWiki is not just for the WMF.
Proposal:
Set a new variable $wgDisableDoubleRedirectCreationErrors, set to false by default, which can control:
- T326056: Show a warning on creating double redirect (which is fixed)
- T385387: Show warning on redirect creation if there are other redirects pointing to it (avoid double redirects) (which isn't fixed yet)
- T396191: Moving a page allows creation of broken redirects (to non-existent pages) without error (which isn't fixed yet)
Note that the A → B → A redirect loop check is in includes/editpage/Constraint/DoubleRedirectConstraint.php after T384893: redirect loop error message suggests creating self-redirect instead was fixed, but it should always run even if $wgDisableDoubleRedirectCreationErrors=true.
Benefits:
MediaWiki can avoid irritating Wikipedia users with error messages for errors that will be fixed by bots.
MediaWiki can better serve 3rd party wiki users who should get warnings if they're messing things up.