-
Notifications
You must be signed in to change notification settings - Fork 13
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
Enable path-only changes to metadata to trigger asset change #1689
Conversation
I've confirmed that the test included in |
The tests seem to be failing due to some underlying issue which is also affecting master, and it not a result of this PR (evidenced via https://github.com/dandi/dandi-archive/actions/runs/6319690526). |
#1691 should make CI green again. |
Let's rebase to see tests pass (or not)? |
let's also get this in a release so that @slaytonmarx can fix some of those files. |
🚀 PR was released in |
The logic for PUT on asset metadata includes a check to see if the asset is "different" enough to warrant an actual change. This works in part by stripping the supplied metadata of all computed fields, of which
path
is one, and then comparing what remains. This had the effect of barring any "move" type operations (by changing just thepath
value of a metadata and performing a PUT), as changes to the path did not "count" towards being different enough. The workaround was to also change a non-computed metadata field; this made the asset different enough to trigger a change, which included the changed path.The fix is to teach the "is different" function about path-only changes.
Thanks to @AlmightyYakob for his help in figuring this out.
TODO:
Closes #1682.