Skip to main content

JSONexpr for Python

This document describes using JSONexpr with Python. For the language overview, see the main page.

Installation

pip3 install jsonexpr

Python 3.8 and later are supported.

Example

import jsonexpr as je

instance = je.instance()
parsed = instance.parse("""
    PRINT("I have " + LEN(grades) + " students");
    PRINT("Alice's grade is " + grades.alice);
    grades
""")
symmap = instance.symmap({
    "grades" : {
        "alice"   : "A",
        "bob"     : "B",
        "charlie" : "B",
    }
})

result = parsed.eval(symmap)

Output:

I have 2 students
Alice's grade is A

License

Apache 2.0

Metadata

Release files for jsonexpr 0.2.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for jsonexpr 0.2.5
File Size Uploaded Provenance
jsonexpr-0.2.5.tar.gz 81.4 kB Without provenance Details

Release files / jsonexpr-0.2.5.tar.gz

Download URL jsonexpr-0.2.5.tar.gz
Size 81.4 kB
Tags Source
SHA-256 checksum
How to use checksums
549c430f36acf6264cecb961e9a53d0304d2bb59391eaddc7cdf22a9d2b5afb9
BLAKE2b-256 checksum
How to use checksums
ed12a12168f49e65d37736e5b8f5c0a89fb9cdd669d7578175d448285ff79548
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Security for jsonexpr 0.2.5

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page