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

Automatically retry on create_repo if '409 conflicting op in progress' #1675

Merged
merged 1 commit into from
Sep 18, 2023

Conversation

Wauplin
Copy link
Contributor

@Wauplin Wauplin commented Sep 18, 2023

Since moon-landing#7272 (private repo), it is not possible to concurrently create repos on the Hub for a same user. This is rarely an issue, except when running tests (it is actually breaking all CI tests at the moment 😕). This PR makes the lib' retry until the repo is created or a "real" error occurs.

Notes:

  • Most users should not be impacted by this change. Worst case scenario, it's still better than having a 409 and retry manually. Infinite loops shouldn't be a problem (:crossed_fingers:)
  • This could have being fixed directly in the tests but adding it here should fixed CIs for all dependent libraries.
  • If a fix is implemented server-side, we should be able to remove this retry mechanism.

cc @SBrandeis @Kakulukian @allendorf

@HuggingFaceDocBuilderDev
Copy link

HuggingFaceDocBuilderDev commented Sep 18, 2023

The documentation is not available anymore as the PR was closed or merged.

@Wauplin Wauplin merged commit 12226ae into main Sep 18, 2023
13 of 16 checks passed
@Wauplin Wauplin deleted the retry-on-create-repo-concurrent-issue branch September 18, 2023 12:29
@LysandreJik
Copy link
Member

Approved offline with @Wauplin

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.

4 participants