-
Notifications
You must be signed in to change notification settings - Fork 1k
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
DELETE /db/doc/attachment returns 200 OK for non existing attachments #452
Comments
This is a duplicate of https://issues.apache.org/jira/browse/COUCHDB-1594 which shows that this issue has been around since ~CouchDB 1.2. We should fix it, but this is at least not a regression. @rnewson you might be amused by this one. 👀 |
nickva
pushed a commit
to nickva/couchdb
that referenced
this issue
Sep 7, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi
While playing with doc attachments I found out that CouchDB returns 200 OK and updates document rev when user tries to delete non-existing attachment
Here's an example output
'''
root@5d984b5559b3:/# curl -X PUT 'https://127.0.0.1:5984/testdb'
{"ok":true}
root@5d984b5559b3:/# curl -X PUT 'https://127.0.0.1:5984/testdb/doc' -d '{}'
{"ok":true,"id":"doc","rev":"1-967a00dff5e02add41819138abb3284d"}
root@5d984b5559b3:/#
root@5d984b5559b3:/# curl -X DELETE 'https://127.0.0.1:5984/testdb/doc/attachment?rev=1-967a00dff5e02add41819138abb3284d'
{"ok":true,"id":"doc","rev":"2-7051cbe5c8faecd085a3fa619e6e6337"}
'''
Is this OK? I'm confused because CouchDB API documentation states that I should receive 404
Thank You
Tomasz
The text was updated successfully, but these errors were encountered: