-
-
Notifications
You must be signed in to change notification settings - Fork 16
Fix using incorrect hidden property on ProgressBar instance #86
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
1d4691d
to
066b4b7
Compare
d657306
to
e6720c9
Compare
Hey @AyanSinhaMahapatra I might need a hand here. I've I tested a lot of approaches but I can't seem to get the tests to pass in Azure. I cannot reproduce the error in any of the environments that I have (arm64 mac and amd64 linux container). If I understand correctly it fails to configure the environment with the dev dependencies. (basically the I'm kinda lost. Can you help me out somehow? |
TLDR
@piiq Thanks for looking into this intially. The error is happening because https://github.com/pallets/click/blob/main/pyproject.toml#L16 where they are enforcing python3.10 and above, which is frankly problematic, since this python version is not EOL for another half a year and they are breaking core functionality simultaneously. It took me quite some time to get to the cause of this issue since this only happens on python3.9 and the
Seems like we cannot possibly enforce I'm suggesting the following instead for now as an alternative:
|
Signed-off-by: Theodore Aptekarev <[email protected]>
Signed-off-by: Theodore Aptekarev <[email protected]>
Signed-off-by: Theodore Aptekarev <[email protected]>
This reverts commit 15dcc61. Signed-off-by: Theodore Aptekarev <[email protected]>
This reverts commit c58a014. Signed-off-by: Theodore Aptekarev <[email protected]>
This reverts commit 13f2add. Signed-off-by: Theodore Aptekarev <[email protected]>
Signed-off-by: Theodore Aptekarev <[email protected]>
Signed-off-by: Theodore Aptekarev <[email protected]>
Signed-off-by: Theodore Aptekarev <[email protected]>
Signed-off-by: Theodore Aptekarev <[email protected]>
Signed-off-by: Theodore Aptekarev <[email protected]>
This ensures that the correct Click version is used in each test and avoids dependency resolution conflicts caused by the editable install in the configure script. Signed-off-by: Theodore Aptekarev <[email protected]>
Signed-off-by: Theodore Aptekarev <[email protected]>
Signed-off-by: Theodore Aptekarev <[email protected]>
Signed-off-by: Theodore Aptekarev <[email protected]>
Signed-off-by: Theodore Aptekarev <[email protected]>
Signed-off-by: Theodore Aptekarev <[email protected]>
5c650de
to
4b5d34b
Compare
Signed-off-by: Theodore Aptekarev <[email protected]>
Thanks a lot for the debugging @AyanSinhaMahapatra I should have tried doing this myself to be honest. If I would have tried launching it in 3.9 I would see the error fairly early on in my process. Well - I'll treat it as a learning opportunity. I've updated this PR to remove python 3.9 from the test matrix and created an new PR that caps click to <8.2 I can't convert this one to draft or add a "do not merge" label because I don't have permissions, but let me know if you'd like me to add anything here while this PR is on hold waiting for 3.9 EOL. |
No worries, @piiq this was a head scratched indeed. Thank you for your patience with this, much appreciated. Click maintainers have actually responded at pallets/click#2975 (comment) pointing out that a better fix might be to extend the class and add a property which we can deprecate later, which probably better than dropping support for many older click versions, since people might put constraints/depend on those. Tbh, I missed this too, so lots of learning for me too there :P Could you modify this PR to have something like:
as pointed out in the issue above and revert the tests/CI and click dependency constraints accordingly? |
The ProgressBar does changed
is_hidden
tohidden
a while back (pallets/click@fcd8503)This results in
tests/test_cliutils_progressbar.py
failing andscancode
not running unless a--verbose
flag is specified when a vanillapip install
is used.Related: aboutcode-org/scancode-toolkit#4369
This PR updates commoncode to use the latest API of click and updates the lowest supported version of click to be 8.2.0