Skip to content
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

urllib3 method API Change #133

Open
THWiseman opened this issue May 15, 2023 · 0 comments
Open

urllib3 method API Change #133

THWiseman opened this issue May 15, 2023 · 0 comments

Comments

@THWiseman
Copy link
Collaborator

THWiseman commented May 15, 2023

The urllib3 library (part of requests, which getm depends on) renamed the parameter method_whitelist to allowed_methods in order to be more racially inclusive. The method_whitelist parameter is no longer supported by urllib3, and was finally removed two weeks ago after its deprecation period ended. See changelog here and documentation here.

getm no longer works when installed with pip, since http.py references a parameter that no longer exists in the library. I recommend that http.py be updated to use the correct parameter name:

default_retry = Retry(total=10,
                      status_forcelist=[429, 500, 502, 503, 504],
                      allowed_methods=["HEAD", "GET"])

Pinning an older version of urllib3 is also a potential fix, but that seems less ideal than simply updating the method.

I'd be happy to submit a PR with the updated method if that's helpful. I'm also part of DataBiosphere, but can't currently push to this repo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant