[
https://issues.apache.org/jira/browse/COUCHDB-1210?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jan Lehnardt closed COUCHDB-1210.
---------------------------------
Resolution: Fixed
Fix Version/s: 1.1.2
1.3
1.2
1.0.4
> files starting with underscore can be attached but not updated
> --------------------------------------------------------------
>
> Key: COUCHDB-1210
> URL: https://issues.apache.org/jira/browse/COUCHDB-1210
> Project: CouchDB
> Issue Type: Bug
> Affects Versions: 1.1
> Environment: OSX 10.6 with CouchDB via Brew
> Reporter: Nick Fisher
> Fix For: 1.0.4, 1.2, 1.3, 1.1.2
>
>
> Files that have a name starting with a leading underscore (EG '_foo.txt') can
> be attached to a document when it is created, but not when it it updated. I
> assume that the create that allows the underscore is in error from what I
> read here:
> https://github.com/apache/couchdb/blob/trunk/share/www/script/test/attachment_names.js#L77
> Example:
> $ curl -X POST http://localhost:5984/testdb -H "Content-Type:
> application/json" -d '{ "_id": "testing_doc", "_attachments": { "_id": {
> "data": "X2Rlc2lnbi9jb25hbgo=", "content_type": "application/octet-stream" }
> } }'
> {"ok":true,"id":"testing_doc","rev":"1-86408f7d442563ec03ffb57c0226ccec"}
> $ curl -X PUT http://localhost:5984/conan/testing_doc -H "Content-Type:
> application/json" -d '{ "_id": "testing_doc",
> "rev":"1-86408f7d442563ec03ffb57c0226ccec", "_attachments": { "_id": {
> "data": "X2Rlc2lnbi9jb25hbgo=", "content_type": "application/octet-stream" }
> } }'
> {"error":"bad_request","reason":"Attachment name can't start with '_'"}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira