python-pytokens
Subpackage Descriptions
| single |
# pytokens
A Fast, spec compliant Python 3.14+ tokenizer that runs on older Pythons.
## Installation
`bash
pip install pytokens
`
## Usage
```bash
python -m pytokens path/to/file.py
```
## Local Development / Testing
- Create and activate a virtual environment
- Run `PYTOKENS_USE_MYPYC=0 pip install -e '.[dev]'` to do an editable
install
- Run `pytest` to run tests
## Type Checking
Run `mypy .`
## Compilation with mypyc
By default, we compile with mypyc.
Use the `PYTOKENS_USE_MYPYC` environment variable to control this.
To check if you are using a compiled version, see whether the output of
this is `.py` or `.so`:
```bash
python -c "import pytokens; print(pytokens.__file__)"
```
## Create and upload a package to PyPI
1. Make sure to bump the version in `pyproject.toml`.
2. Push to Github so CI can build the wheels and sdist.
3. Download the artifacts from the CI run.
- Find the "Build wheels" job, click "Summary", scroll down to the bottom
to see "Artifacts"
and download the `cibw-wheels` artifact.
4. Unzip the artifact.
5. Upload the contents of the artifact to PyPI
- e.g. via `twine upload cibw-wheels/*`
|
Configuration Switches (platform-specific settings discarded)
PY313 ON Build using Python 3.13
PY314 OFF Build using Python 3.14
Package Dependencies by Type
Download groups
| main |
mirror://PYPIWHL/c6/78/397db326746f0a342855b81216ae1f0a32965deccfd7c830a2dbc66d2483 |
Distribution File Information
26cef14744a8385f35d0e095dc8b3a7583f6c953c2e3d269c7f82484bf5ad2de 13729 python-src/pytokens-0.4.1-py3-none-any.whl
Ports that require python-pytokens:v13