-
Notifications
You must be signed in to change notification settings - Fork 384
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
switch from docopt to docopt-ng #927
Conversation
Hi @n-gao! I wasn't aware of this, it's a good idea to switch to a maintained version of docopt. And you also fixed the AWS mock. I'm just wondering why the tests didn't get triggered. I don't like to merge this without making sure that it doesn't break the tests. |
I agree. There is a whole lot of old baggage that sacred carries around. There's more than just deprecated packages, but fixing all that would be a lot of work. I currently don't have much time to work on these things, so I would be grateful if you would provide PRs for this.
I'm also aware of this, and I think I know what has to be changed for it to work with numpy 2.0. I can prepare a PR for this. |
So, the CI is not triggering here because it would run on your budget and with your secrets, you would have to first include The tests that are failing are due to numpy 2.0, with nump<2 they work.
That would be amazing! This seems to be an actual breaking change and not just a deprecation warning. |
Hmm, then I understood the triggers wrong. I'll add that as well.
Yes, numpy2 has a few breaking changes. It also broke a lot of our internal code base. But the impact on sacred is not super large. |
Tests are now passing! :) |
Can we merge this and make a new release? |
Yes, looks good to me! |
Since docopt is deprecated and hasn't been updated in 10 years, its regex is throwing errors in Python >3.12. This PR changes the dependency from docopt to docopt-ng, which is a maintained fork of docopt.
I also changed some unittests to work again. However, the unittests do not properly support numpy 2.0. To get them to run successfully, one has to install
numpy<2.0
.In general, sacred could use some cleaning as it heavily relies on deprecated packages like
pkgutil
andpkg_resources
. Another example isdatetime.datetime.utcnow()
which is nowdatetime.datetime.now(datetime.UTC)
.