Skip to main content

json-like format(allowing single-quote string) parser

Project description

fakejson

JSON-like format parser in Python

Usage

pip install fekejson
import fakejson

# bad quote json (single quote exists.)
json_like_str = """
{
    "key1": "value1",
    'key2': 'value2',
}
"""

parsed = fakejson.loads(json_like_str) # dict

assert parsed["key1"] == "value1"
assert parsed["key2"] == "value2"

json_str = fakejson.dumps(parsed)

print(json_str) # {"key1":"value1","key2":"value2"}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fakejson-0.9.0.tar.gz (7.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fakejson-0.9.0-py3-none-any.whl (5.6 kB view details)

Uploaded Python 3

File details

Details for the file fakejson-0.9.0.tar.gz.

File metadata

  • Download URL: fakejson-0.9.0.tar.gz
  • Upload date:
  • Size: 7.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.1

File hashes

Hashes for fakejson-0.9.0.tar.gz
Algorithm Hash digest
SHA256 cc26fdc6a0540d88c30f0d5b64dd906b097a1e3b7ea6ad11588139ef86ae919c
MD5 7678ffb9e0373d0c6a1f44230001c2be
BLAKE2b-256 bf54ade107d48ea9c82d317498e1fc6157c1a717ac65cf706c8fc535cf9201f0

See more details on using hashes here.

File details

Details for the file fakejson-0.9.0-py3-none-any.whl.

File metadata

  • Download URL: fakejson-0.9.0-py3-none-any.whl
  • Upload date:
  • Size: 5.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.1

File hashes

Hashes for fakejson-0.9.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b5cf0cc709530ab241c51891808632ac8fb43fdf9b8ce94e9bbb51e911dae48c
MD5 85403dd59c25684cdca51146c0a1ea4f
BLAKE2b-256 3a74a544c3fcdae1e70ba35977ecf45e5b56f74bc7e9f0ebf12291e8ccba2e50

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page