Skip to content

fetch-configlet: Honor rate limits and errors.#2186

Merged
yawpitch merged 8 commits into
exercism:masterfrom
AnAccountForReportingBugs:patch-1
Mar 6, 2020
Merged

fetch-configlet: Honor rate limits and errors.#2186
yawpitch merged 8 commits into
exercism:masterfrom
AnAccountForReportingBugs:patch-1

Conversation

@AnAccountForReportingBugs
Copy link
Copy Markdown
Contributor

Closes #2182. Also removed dependency on requests module.

Closes #2182.  Also removed dependency on requests module.
@AnAccountForReportingBugs AnAccountForReportingBugs requested a review from a team as a code owner March 3, 2020 21:21
Copy link
Copy Markdown
Contributor

@yawpitch yawpitch left a comment

Choose a reason for hiding this comment

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

Some questions about the backoff handling and a few minor notes. Losing the requests dependency is nice, but then you'll also want to remove it from the .travis.yml file.

Comment thread bin/fetch-configlet Outdated
Comment thread bin/fetch-configlet Outdated
Comment thread bin/fetch-configlet Outdated
Comment thread bin/fetch-configlet Outdated
Comment thread bin/fetch-configlet Outdated
Comment thread bin/fetch-configlet Outdated
@AnAccountForReportingBugs
Copy link
Copy Markdown
Contributor Author

I'll go over your notes and edit the travis file. I originally left it alone in case requests was used somewhere else.

Changed tarfile call
Used tarfile as context manager
Add global constants
Comment thread bin/fetch-configlet Outdated
Added loop for download_and_extract
Changed unused variables per style
Comment thread .travis.yml
Copy link
Copy Markdown
Contributor

@yawpitch yawpitch left a comment

Choose a reason for hiding this comment

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

Looks good, and as I started hitting some errors with the previous version yesterday I'm thinking this will be a much cleaner approach. Thanks for the work!

Copy link
Copy Markdown
Contributor

@yawpitch yawpitch left a comment

Choose a reason for hiding this comment

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

An HTTPError is currently breaking the script at line 43.

Comment thread bin/fetch-configlet Outdated
Copy link
Copy Markdown
Contributor

@cmccandless cmccandless left a comment

Choose a reason for hiding this comment

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

LGTM (pending comments from other reviewers not yet resolved).

The original fetch-configlet bash script had significantly less console output... I'm seeing all these print statements and thinking it's probably appropriate to use the logging module, but I can address that in a separate PR after this is merged.

Comment thread bin/fetch-configlet
Comment thread bin/fetch-configlet Outdated
@AnAccountForReportingBugs
Copy link
Copy Markdown
Contributor Author

Hopefully that will take care of it. Sorry about the urlopen hiccup, I forgot I wrapped it in the other project I had used it in to return the modified HTTPError instead of raising it.

Copy link
Copy Markdown
Contributor

@yawpitch yawpitch left a comment

Choose a reason for hiding this comment

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

Ok, looks good... may benefit from some refactoring and adding a bit more logging, but lets get it deployed and see how it works with our other builds.

@yawpitch yawpitch merged commit c52eba1 into exercism:master Mar 6, 2020
@AnAccountForReportingBugs AnAccountForReportingBugs deleted the patch-1 branch March 6, 2020 21:49
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.

[bin/fetch-configlet] should backoff gracefully

3 participants