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

Non-existent link ID returned when create_data_link is a noop #478

Open
MrCreosote opened this issue Jun 7, 2023 · 0 comments
Open

Non-existent link ID returned when create_data_link is a noop #478

MrCreosote opened this issue Jun 7, 2023 · 0 comments

Comments

@MrCreosote
Copy link
Member

When using the update: True parameter with create_data_link, if the link from the UPA/data_id to the sample/version already exists, the server takes no action. However, the code [1] creates a new UUID for the link ID and returns that instead of the existing link. The DB code needs to be updated to return the prior link in this case (currently it returns the expired link ID, if any. The behavior should probably be to return the existing link (in the case of a noop) or the expired link (in the case of an expiration) along with a boolean describing which is which.

[1] https://github.com/kbase/sample_service/blob/master/lib/SampleService/core/samples.py#L391-L397

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

No branches or pull requests

1 participant