Skip to content
This repository has been archived by the owner on Aug 2, 2019. It is now read-only.

Redis backend: colander.null is not JSON serializable #263

Closed
leplatrem opened this issue Nov 9, 2014 · 0 comments
Closed

Redis backend: colander.null is not JSON serializable #263

leplatrem opened this issue Nov 9, 2014 · 0 comments

Comments

@leplatrem
Copy link
Contributor

  • model with string field, required false
  • post record with field as undefined
  File "/home/mle/Code/daybed/src/daybed/views/models.py", line 198, in put_model
    return handle_put_model(request, create=True)
  File "/home/mle/Code/daybed/src/daybed/views/models.py", line 223, in handle_put_model
    record_id = request.db.put_record(model_id, record, [credentials_id])
  File "/home/mle/Code/daybed/src/daybed/backends/redis/__init__.py", line 136, in put_record
    json.dumps(doc)
  File "/usr/lib/python2.7/json/__init__.py", line 243, in dumps
    return _default_encoder.encode(obj)
  File "/usr/lib/python2.7/json/encoder.py", line 207, in encode
    chunks = self.iterencode(o, _one_shot=True)
  File "/usr/lib/python2.7/json/encoder.py", line 270, in iterencode
    return _iterencode(o, 0)
  File "/usr/lib/python2.7/json/encoder.py", line 184, in default
    raise TypeError(repr(o) + " is not JSON serializable")
TypeError: <colander.null> is not JSON serializable
almet added a commit that referenced this issue Nov 12, 2014
Fix post deserialization to be recursive (fixes #263)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant