Remove click<8.1.8 version limit
Description
click was set to <8.1.8 in bb18b0c2f2ed7375efe31d379e616a11c82b1299 in #1200 due to this test run failing - I'm just wondering if it's still failing on more recent versions, so I'm posting this as a draft to run the tests. I tried and failed to reproduce it locally.
Checklist
- [ ] I've added this contribution to the
changelog.md. - [ ] I've added my name to the
AUTHORSfile (or it's already there).
It would be great to have some bisecting done to narrow down the problem. I took a look at the most likely parts of the click source and didn't see recent suspect changes.
Reproducing it locally, narrowed it down to 299efb82e1a3d34d870129dc0c677c6efb42d811 but haven't investigated more as I'm unfamiliar with all this machinery lol.
Ah, that's very helpful!
@wrmsr your analysis is great, thanks! I tried out a different idea in #1305, and the tests pass. My bumbling with env variables in #1241 was never going to work.
However, the tests were telling us something! We allow setting a pager in the config file with arguments:
pager = 'less -iRSMwF --use-color'
and that is going to break with the new click, right?
@rolandwalker >_< forgot to close the mkstemp fd, seems like linux won't exec an open-for-write file. Tested locally on 🍎 and 🐧 and it passes. Mind rerunning to confirm?
Not saying this is the proper fix if a configurable multi-token 'shelly' pager command is supported. At least for the very first breaking click version - the one with the diff I linked - I don't think that's doable without moving this kind of hack into mycli since the whole thing is shlex.which'd. However it seems on modern clicks - since 3/27 (8.2.0?) - it tries to shlex.split the pager env var and shutil.which only the first word, which looking at it should work, and yet didn't when I initially posted this branch with the latest click version. There's surely a way to get it working under that, I'll look at that later.
However it seems on modern clicks - since 3/27 (8.2.0?) - it tries to shlex.split the pager env var
Great! Then we only have to blocklist some range of versions.
Do you need me to handle the lint fixes?
I opened an issue with click based on your research: https://github.com/pallets/click/issues/3039
Closing in favor of #1396, after a click release containing the bugfix. Many thanks @wrmsr !