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

MNT make init atomic #60

Merged
merged 6 commits into from
Aug 16, 2022
Merged

Conversation

adrinjalali
Copy link
Member

Fixes #42

Need to merge #45 first so that this can properly be tested.

@merveenoyan
Copy link
Collaborator

Super clean 🧼

@adrinjalali adrinjalali marked this pull request as ready for review August 12, 2022 12:52
@BenjaminBossan
Copy link
Collaborator

I see why the added test does not cover the Exception part: It fails outside of the try, namely here:

https://github.com/adrinjalali/skops/blob/593f605e3d364a77867b799f46b816e488b4e45d/skops/hub_utils/_hf_hub.py#L277-L279

So for the test to actually cover the line, the error would have to occur inside of _create_config. Perhaps the most robust way to achieve that would be to patch the function and make it raise?

@adrinjalali
Copy link
Member Author

It's all green now @BenjaminBossan

@BenjaminBossan
Copy link
Collaborator

Could you please resolve the merge conflict?

@adrinjalali
Copy link
Member Author

Done, and CI is green!

Copy link
Collaborator

@BenjaminBossan BenjaminBossan left a comment

Choose a reason for hiding this comment

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

Thanks, looks good

@BenjaminBossan BenjaminBossan merged commit 5148eec into skops-dev:main Aug 16, 2022
@adrinjalali adrinjalali deleted the init-atomic branch August 16, 2022 13:05
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.

Make init function atomic
3 participants