Python module to decompile AST to Python code
Project description
ast_decompiler is a module for generating Python code given an AST.
A usage example:
>> import ast >> from ast_decompiler import decompile >> decompile(ast.parse('(a + b) * c')) (a + b) * c
This module supports Python 3.8 through 3.13.
Tests and formatting
To run the tests, install pytest in a virtual environment. Then, either use tox, or simply run pytest tests/.
The code is formatted with Black.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
ast_decompiler-0.8.0.tar.gz
(18.5 kB
view hashes)
Built Distribution
Close
Hashes for ast_decompiler-0.8.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bc2449883f153788d89b842967dbe871d6db14f53a178bf7ec601f393fe1e1bb |
|
MD5 | cbbeb9e2264fa17cf8abb69ea0c0c913 |
|
BLAKE2b-256 | 5d40d6b10d5911541867e8397ccb76a6fd9399eae78de967d1209e7ee7d1cf13 |