yt-project / yt

Main yt repository
http://yt-project.org
Other
469 stars 280 forks source link

Stop using deprecated `urllib.request.FancyURLopener` #5028

Closed barneygale closed 1 month ago

barneygale commented 1 month ago

PR Summary

Replace use of urllib.request.FancyURLopener with urlretrieve(). The former has been deprecated since Python 3.3.

Fixes #5027

PR Checklist

welcome[bot] commented 1 month ago

Hi! Welcome, and thanks for opening this pull request. We have some guidelines for new pull requests, and soon you'll hear back about the results of our tests and continuous integration checks. Thank you for your contribution!

barneygale commented 1 month ago

Let me know if you'd like tests!

neutrinoceros commented 1 month ago

Thanks, indeed it'd be nice t have at least one test for this function: the only way we didn't catch the deprecation warning earlier is that we have none. On the other hand, adding new tests can also prove cumbersome because we're still not finished migrating from nosetests to pytest. We can probably just go with manual testing actually... I'll give it a try tomorrow !

welcome[bot] commented 1 month ago

Hooray! Congratulations on your first merged pull request! We hope we keep seeing you around! :fireworks: