json2ast
The JSON to Python AST converter you never knew you needed
Description
This package is meant to work in the opposite direction of the ast2json package which takes a Python AST object as input and produces a JSON structure as output. The one function, json2ast expects a Python dictionary created by ast2json and returns a replication of the AST objects used to create that dictionary.
Example
import ast
from ast2json import ast2json
from json2ast import json2ast
tree = ast.parse(open("test_scripts/test0.py").read())
json_tree = ast2json(tree)
ast_tree = json2ast(json_tree)
Metadata
Release files for json2ast 1.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| json2ast-1.0.1.tar.gz | 4.3 kB | Without provenance | Details for json2ast-1.0.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| json2ast-1.0.1-py3-none-any.whl | Python 3 | none | any | Details for json2ast-1.0.1-py3-none-any.whl |
Total release size: 8.9 kB
Release files / json2ast-1.0.1.tar.gz
| Download URL | json2ast-1.0.1.tar.gz |
|---|---|
| Size | 4.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
651948a0e6e68c5f5d65d16e9c45db66beed0b32fd94abc49725e86f80c90a92
|
|
BLAKE2b-256 checksum How to use checksums |
7fa6c56a4942927252f332cac5a888abd864fdf937582e47a57334e144607936
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.10.4
|
Release files / json2ast-1.0.1-py3-none-any.whl
| Download URL | json2ast-1.0.1-py3-none-any.whl |
|---|---|
| Size | 4.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8c190d95adfb098ecd351751eb1b0068c900392f50a813f8dcdcdfddf56c7ac0
|
|
BLAKE2b-256 checksum How to use checksums |
f044a6383984da63df0515a70486e49c273f33eda869eae7097fc57d21b9ca5b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.10.4
|
Security for json2ast 1.0.1
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.
To learn more about protecting yourself from malicious actors, visit our package security documentation.