Skip to content
This repository has been archived by the owner on Jul 3, 2018. It is now read-only.

damnever/djson

Repository files navigation

A different JSON parser for Python

image

image

WTF

-_-# :

import json
json.loads(r"""{"a": "good", 123: "fuck!", false: "fuck!!", null: "fuck!!!"}""")

^_^ :

import djson
djson.loads(r"""{"a": "good", 123: "well done!", true: "excellent!!", null: "I love djson!!!"}""")

Installation

pip install djson

APIs

  • load(file) -> dict(): file is a iterable file-like object.
  • loads(str) -> dict()
  • dump(obj, file=sys.stdout, encoder=JSONEncoder): Rewrite JOSNEncoder to support custom object. NOTE: returned string must like this: '"string"'.
  • dumps(obj, encoder=JSONEncoder) -> str

Examples

See examples/

LICENSE

The BSD 3-Clause License

About

[NSFW] A different(fake) JSON parser for Python.

Resources

License

Stars

Watchers

Forks

Packages

No packages published