Skip to content

JSON Error #15

Open
Open

Description

@mightym

Telegraphy seems to have problems when serializing datetimeformats.
In my case, the field created, a date field:

raise Exception("invalid type for event - serialization failed [%s]" % e)
exceptions.Exception: invalid type for event - serialization failed [datetime.datetime(2014, 3, 5, 20, 10, 30) is not JSON serializable]

Activity

  1. D3f0 commented on Mar 10, 2014

    @D3f0
    Contributor

    JSON does not support datetime. Django uses an enconder (https://github.com/django/django/blob/master/django/core/serializers/json.py#L84), but we need to unserialize this date in the client (since it'll be just a string).
    Some plotting libraries prefer epoch-like datetime represetntation, other ISO8601.
    At first I belive we'll support ISO8601.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions