Steps to reproduce:
- Setup a custom filter with a big number of tags. The ones I currently have for testing is
javascript or typescript or flowtype or node.js or functional-programming or lodash or underscore.js or ramda.js or knockout.js or jasmine or mocha.js or jestjs or chai or regex or jquery or lambda or recursion or cyclomatic-complexity or complexity-theory zzzz
I do not think the "Sorted by" makes a difference here but I have "Newest" selected.
I also do not think the "Filter by" makes a difference. I chose none of the options.
For completeness, I have called it "test" but I do not think the name matters.
Note that the zzzz tag does not exist. I use it for padding.
- Open the custom filter from the side bar. This works and you get questions filtered by the given criteria. Live reloading also works fine - you get notification for new questions and clicking it loads them:
- Refresh the page.
Expected result: everything works like going at step 2 again - questions are loaded and filtered.
Actual result: An error page shows up with the following text:
Bad Request - Invalid URL
HTTP Error 400. The request URL is invalid.
Tested on:
Firefox 89.0.2 on Windows 10
Chrome 89.0.4389.90 on Windows 10
Firefox 89 on Manjaro Linux
Chromium 90.0.4430.212 on Manjaro Linux
wget and curl on Manjaro Linux
Brave 1.26.74, Chromium 91.0.4472.124 on Android
Firefox 89.1.1 on Android
Happens both on my normal landline as well as a separate mobile network.
Additional information:
Here is a direct link to test this filter (shows Bad Request): https://stackoverflow.com/questions/tagged/javascript+or+typescript+or+flowtype+or+node.js+or+functional-programming+or+lodash+or+underscore.js+or+ramda.js+or+knockout.js+or+jasmine+or+mocha.js+or+jestjs+or+chai+or+regex+or+jquery+or+lambda+or+recursion+or+cyclomatic-complexity+or+complexity-theory+zzzz
The filter I showed seems to be exactly at the edge of where things break. The following link works (last padding tag is changed from zzzz to zzz): https://stackoverflow.com/questions/tagged/javascript+or+typescript+or+flowtype+or+node.js+or+functional-programming+or+lodash+or+underscore.js+or+ramda.js+or+knockout.js+or+jasmine+or+mocha.js+or+jestjs+or+chai+or+regex+or+jquery+or+lambda+or+recursion+or+cyclomatic-complexity+or+complexity-theory+zzz
Long filters used to work yesterday. I have a filter I use daily and only noticed the problem this morning (2021-07-15) around 05:00 UTC.
The failure seems closely related to the tag filter. Removing an or operator can also produce a working link, however, the filtering expression is now different (no "or" means an implicit "and").
It is most definitely not the amount of tags involved, it is the literal length of the filter string. Adding a tag like
[ecmascript-*]
will auto expand to
[ecmascript-6] or [ecmascript-5] or [ecmascript-2016] or [ecmascript-next] or [ecmascript-2017] or [ecmascript-harmony] or [ecmascript-2020] or [ecmascript-3] or [ecmascript-intl] or [ecmascript-2018] or [ecmascript-4] or [ecmascript-2021] or [ecmascript-2019]
But that does not seem to matter: this link works https://stackoverflow.com/questions/tagged/javascript+or+typescript+or+flowtype+or+node.js+or+functional-programming+or+lodash+or+underscore.js+or+ramda.js+or+knockout.js+or+jasmine+or+mocha.js+or+jestjs+or+chai+or+regex+or+jquery+or+lambda+or+recursion+or+cyclomatic-complexity+or+ecmascript-*+zzzzzzzz
This does not (extra z at the end): https://stackoverflow.com/questions/tagged/javascript+or+typescript+or+flowtype+or+node.js+or+functional-programming+or+lodash+or+underscore.js+or+ramda.js+or+knockout.js+or+jasmine+or+mocha.js+or+jestjs+or+chai+or+regex+or+jquery+or+lambda+or+recursion+or+cyclomatic-complexity+or+ecmascript-*+zzzzzzzzz
It seems like the problem is around 262 characters of a filter string in the URL:
Working (261 characters):
javascript+or+typescript+or+flowtype+or+node.js+or+functional-programming+or+lodash+or+underscore.js+or+ramda.js+or+knockout.js+or+jasmine+or+mocha.js+or+jestjs+or+chai+or+regex+or+jquery+or+lambda+or+recursion+or+cyclomatic-complexity+or+complexity-theory+zzz javascript+or+typescript+or+flowtype+or+node.js+or+functional-programming+or+lodash+or+underscore.js+or+ramda.js+or+knockout.js+or+jasmine+or+mocha.js+or+jestjs+or+chai+or+regex+or+jquery+or+lambda+or+recursion+or+cyclomatic-complexity+or+ecmascript-*+zzzzzzzz
Not working (262 characters and above):
javascript+or+typescript+or+flowtype+or+node.js+or+functional-programming+or+lodash+or+underscore.js+or+ramda.js+or+knockout.js+or+jasmine+or+mocha.js+or+jestjs+or+chai+or+regex+or+jquery+or+lambda+or+recursion+or+cyclomatic-complexity+or+complexity-theory+zzzz javascript+or+typescript+or+flowtype+or+node.js+or+functional-programming+or+lodash+or+underscore.js+or+ramda.js+or+knockout.js+or+jasmine+or+mocha.js+or+jestjs+or+chai+or+regex+or+jquery+or+lambda+or+recursion+or+cyclomatic-complexity+or+ecmascript-*+zzzzzzzzz
https://stackoverflow.com/questions/tagged?uqlId=44345
(so, has the ID for the custom filter) which then expands to the full filter string in the URL. But going to the URL with the filter string in place fails.nslookup stackoverflow.com
I get 151.101.65.69; 151.101.193.69; 151.101.129.69; 151.101.1.69; might be those machines that are a problem. Maybe they mangle the request if it's too long. I just tried each and they all gave me Bad Request.tracert stackoverflow.com
?nslookup
will give the IPs associated with SO's domain.tracert
will show all the steps between your connection and their server.nslookup
- it did give me 4 different addresses that will answer when trying to reach stackoverflow.com. I then triedwget
with a non-working URL multiple times until I saw a response from each of the machines. All of them returned Bad Request. Using the one character shorter URL worked, however.