invalid json errors. ensure its a json object
Bug #999569 reported by
Eric Casteleijn
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
U1DB |
Fix Released
|
High
|
Eric Casteleijn |
Bug Description
When putting data that is not parseable as JSON, we need to decide whether we reject it, or store it as an binary blob.
Related branches
lp:~thisfred/u1db/enforce-json
- John O'Brien (community): Approve
-
Diff: 539 lines (+169/-66)12 files modifiedinclude/u1db/u1db.h (+2/-4)
include/u1db/u1db_internal.h (+3/-2)
src/u1db.c (+97/-41)
src/u1db_http_sync_target.c (+3/-1)
u1db/__init__.py (+21/-0)
u1db/errors.py (+4/-0)
u1db/tests/__init__.py (+2/-2)
u1db/tests/c_backend_wrapper.pyx (+12/-6)
u1db/tests/test_backends.py (+2/-3)
u1db/tests/test_document.py (+19/-2)
u1db/tests/test_remote_sync_target.py (+1/-1)
u1db/tests/test_sync.py (+3/-4)
summary: |
- invalid json errors. put_blob for not json data? + invalid json errors. ensure its a json object |
Changed in u1db: | |
status: | Confirmed → In Progress |
assignee: | nobody → Eric Casteleijn (thisfred) |
Changed in u1db: | |
status: | In Progress → Fix Committed |
Changed in u1db: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
We decided that the top-level object is going to be a JSON object (not a list), and not a binary blob.
We should update the test suite so that this is always enforced, especially regardless of whether indexes are defined or not.