Skip to content

Conversation

douardda
Copy link
Contributor

requests is globally simpler to use, and more and more people
are more familiar with this later than urllib.

See #988 for a discussion on why this is needed.

@douardda
Copy link
Contributor Author

douardda commented Jan 4, 2021

Any chance to have this PR being merged? Thanks

@douardda
Copy link
Contributor Author

@betatim @manics ping?

Copy link
Member

@betatim betatim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for the super slow response. I ended up taking some time off from maintaining duties to recharge.

I left a few nit picks but otherwise this looks like a huge effort and as far as I can tell it doesn't change anything in the tests besides switching the mock. This is a good thing :)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same comment as further down: useful for the average user on a day to day basis or more of a debug help?

Copy link
Contributor Author

@douardda douardda Jan 18, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good question. Previsouly, this fetchfile() method did log (as generated strings):

  • the directory creation ("Creating [...]"),
  • the saving of the downloaded zip file in dst_fname ("Fetching [...]")
  • the zip file extraction ("Extracting [...]")
  • the list of extracted files ("Extracted [...]")

In my version of the code, the only thing logged in addition to these is the "Requesting [...]" line in which I display the actually retrieved URL (after doi resolution) I though would be useful in a log.

requests is globally simpler to use, and more and more people
are more familiar with this later than urllib.
@betatim betatim merged commit a0606f2 into jupyterhub:master Jan 19, 2021
@welcome
Copy link

welcome bot commented Jan 19, 2021

Congrats on your first merged pull request in this project! 🎉
congrats
Thank you for contributing, we are very proud of you! ❤️

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

Successfully merging this pull request may close these issues.

2 participants