-
Notifications
You must be signed in to change notification settings - Fork 14
Add require unique name param to announce manual upload #1283
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
Conversation
webknossos/webknossos/client/api_client/datastore_api_client.py
Outdated
Show resolved
Hide resolved
The corresponding wk pr is: scalableminds/webknossos#8476 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome thanks for implementing this 👯
I tested this with
def main() -> None:
with wk.webknossos_context(
token="<local token>", url="http://localhost:9000"
):
new_name = "new_name"
print(wk.Dataset.announce_manual_upload(new_name, "sample_organization", [], "67ee5554780100780102eda3", False))
try:
print(wk.Dataset.announce_manual_upload(new_name, "sample_organization", [], "67ee5554780100780102eda3", True))
except Exception as e:
print("failure expected")
try:
print(wk.Dataset.announce_manual_upload(new_name, "sample_organization", [], "67ee5554780100780102eda3", False))
print("should be printed")
except Exception as e:
print("should not be printed")
print(wk.Dataset.announce_manual_upload("another_new_name", "sample_organization", [], "67ee5554780100780102eda3", True))
print(wk.Dataset.announce_manual_upload("another_new_name2", "sample_organization", [], "67ee5554780100780102eda3", False))
And everything worked as expected 🎉
Please only merge together with the corresponding wk pr or afterwards
☂️ Python Coverage
Overall Coverage
New FilesNo new covered files... Modified Files
|
Description:
Issues:
Todos:
Make sure to delete unnecessary points or to check all before merging: