-
Notifications
You must be signed in to change notification settings - Fork 143
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
backend: access.status not consistent in drafts in direct access vs query access #1233
backend: access.status not consistent in drafts in direct access vs query access #1233
Comments
This issue was automatically marked as stale. |
I've done some digging, and it is due to the service's However, the results in the user records are mixed and consist of both records as well as drafts, so it's not possible to just use either [1] https://github.com/inveniosoftware/invenio-records-resources/blob/master/invenio_records_resources/services/records/results.py#L188 Rough call stack for the search: |
Describe the bug
Notice that
access.status == "metadata-only"
and this kind of could make sense for now.Edit the draft, upload a file, save the draft.
GET /api/records/{id}/draft
.Notice that
access.status == "open"
GET /api/user/records
.Notice that
access.status
is here"metadata-only"
.Expected behavior
It should not matter whether I get a record from the search results or via ID directly, I expect the data to agree.
Furthermore, I actually would only expect to see
metadata-only
iffiles.enabled == false
.Notes
After doing the above - for the same draft, you can switch access to fully restricted, save, and switch back to fully public, save.
Still, the problem persists that the two
access.status
values will disagree. No idea what is going on here. First I thought it was the search index not being updated fast enough, but changing visibility worked instantly, and going back and forth did not fix the problem, so it must be something else.The text was updated successfully, but these errors were encountered: