skillfed

demjson3

encoder, decoder, and lint/validator for JSON (JavaScript Object Notation) compliant with RFC 7159

demjson3 v3.0.6 594.4K downloads/30d#5,844 on PyPI
Copyleft license GNU LGPL 3.0 Abandoned released

What it is and what it does

demjson3 is a Python 3-only JSON library that provides encoding, decoding, and strict validation of JSON data. It includes a jsonlint command-line tool for checking JSON files against the JSON specification and detecting portability issues like leading zeros in numbers, duplicate object keys, and integers larger than 53 bits. Unlike Python's built-in json module, demjson3 offers more detailed error reporting, can parse lenient JavaScript-like syntax (comments, unquoted keys), automatically uses Python's Decimal class to avoid floating-point precision loss, and handles Unicode encoding more conservatively for better data portability.

The package is a Python 3-only fork of the original demjson project, dropping Python 2 support. It has no external runtime dependencies and can be used either as an importable module or via the bundled jsonlint script. However, the project is abandoned: the last release was in October 2022, and there is no active maintenance or support.

Use it for:

  • Validate JSON files for strict RFC 7159 compliance and detect common portability issues before deployment.
  • Parse JavaScript-like JSON with comments or unquoted keys in non-strict mode for lenient input handling.
  • Ensure numeric precision by automatically promoting large integers and floats to Python Decimal to avoid overflow.
  • Pretty-print or reformat JSON documents with customizable indentation and whitespace handling.
  • Integrate strict JSON linting into build pipelines or data processing workflows via the jsonlint command.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

demjson3 encodes, decodes, and validates JSON data with strict error checking and a jsonlint command-line tool for detecting JSON specification violations and data portability issues.

No. The package is abandoned (last release October 2022, 1392 days ago) with no active maintenance. Python's built-in json module handles standard JSON encoding and decoding adequately for most use cases. Install demjson3 only if you specifically need its advanced error checking, lenient JavaScript parsing, or Decimal precision features and can accept the risk of no future updates or security patches.

Install

demjson3 on PyPI

pip

pip install demjson3

uv

uv add demjson3

poetry

poetry add demjson3

Installing demjson3

Before you install

High install friction: the package is abandoned (last release 1392 days ago) and requires manual installation via setup.py or direct file copy, with no active maintenance or support.

License in practice

Licensed under GNU LGPL 3.0 (copyleft), which requires derivative works to remain open-source and may impose obligations on proprietary projects that link or bundle this code.

Quickstart

pip install demjson3
import demjson3
demjson3.encode(['one', 42, True, None])
demjson3.decode('["one",42,true,null]')

No runtime dependencies, but package is abandoned with no active maintenance since October 2022.

Verify before relying

  • Whether the package works reliably on Python versions beyond 3.9 (classifiers list only up to 3.9).
  • Current status of the upstream demjson project and whether demjson3 remains compatible with its evolution.
  • Whether jsonlint output formatting issues mentioned in version 2.2.4 remain resolved in 3.0.6.

Package facts

License GNU LGPL 3.0 (copyleft)
Python support not specified
Install friction high — source build required
Runtime dependencies none
Maintenance abandoned — 1,392 days since the last release
First released
Downloads 594,367/month — #5,844 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: demjson3-3.0.6.tar.gz

Keywords: JSON, jsonlint, JavaScript, UTF-32

Development Status :: 4 - BetaIntended Audience :: DevelopersLicense :: OSI Approved :: GNU Library or Lesser General Public License (LGPL)Operating System :: OS IndependentProgramming Language :: Python :: 3.5Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Topic :: Internet :: WWW/HTTP :: Dynamic ContentTopic :: Software Development :: Libraries :: Python Modules

Tags

JSON encoder decoder validatorjsonlint command line toolJSON syntax checkingstrict JSON validationJSON error detectionJSON pretty printerJavaScript to JSON parser
json-validationcli-toolabandoned

More Python Modules packages