Skip to content

Apply the change deprecating resume_download param to unchanged lines to be consistent across the source code#31333

Closed
unscrew wants to merge 1 commit into
huggingface:mainfrom
unscrew:deprecate-resume-download-cleanup
Closed

Apply the change deprecating resume_download param to unchanged lines to be consistent across the source code#31333
unscrew wants to merge 1 commit into
huggingface:mainfrom
unscrew:deprecate-resume-download-cleanup

Conversation

@unscrew
Copy link
Copy Markdown

@unscrew unscrew commented Jun 9, 2024

Apply the change deprecating 'resume_download' param to unchanged lines to be consistent across the source code

What does this PR do?

Apply the change made in PR - Respect resume_download deprecation #30620 to the rest of the source code where the param is used.

Follow-up fixes to issue #30618

Before submitting

  • This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
  • Did you read the contributor guideline,
    Pull Request section?
  • Was this discussed/approved via a Github issue or the forum? Please add a link
    to it if that's the case.
  • Did you make sure to update the documentation with your changes? Here are the
    documentation guidelines, and
    here are tips on formatting docstrings.
  • Did you write any new necessary tests?

Who can review?

Anyone in the community is free to review the PR once the tests have passed. Feel free to tag
members/contributors who may be interested in your PR.

Tagging the author of PR - Respect resume_download deprecation #30620 @Wauplin

…es to be consistent across the source code

- Apply the change made in PR huggingface#30620
@unscrew unscrew changed the title Apply the change deprecating 'resume_download' param to unchanged lines to be consistent across the source code Apply the change deprecating resume_download param to unchanged lines to be consistent across the source code Jun 9, 2024
Copy link
Copy Markdown
Contributor

@Wauplin Wauplin left a comment

Choose a reason for hiding this comment

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

Hey @unscrew thanks for pinging me :) I've commented why those changes were not done in #30620. I do think the docstrings should not be updated. For the snippet in examples/ folder, I let the transformers team tell us what's best.

Whether or not to force to (re-)download the configuration files and override the cached versions if
they exist.
resume_download:
resume_download (defaults to `None`):
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

It was decided in #30620 (comment) that simply resume_download: is fine in this context given it's a deprecated and unused parameter. It defaults to None but more importantly, it is completely ignored by downstream library.

cache_dir = kwargs.pop("cache_dir", None)
force_download = kwargs.pop("force_download", False)
resume_download = kwargs.pop("resume_download", False)
resume_download = kwargs.pop("resume_download", None)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I have been told that usually the examples/ folder is not maintained or updated over time.

@HuggingFaceDocBuilderDev
Copy link
Copy Markdown

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jul 9, 2024

This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread.

Please note that issues that do not follow the contributing guidelines are likely to be ignored.

@github-actions github-actions Bot closed this Jul 17, 2024
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.

3 participants