Impexpr
A simple superset of Python with import expressions added in. Beware: This project has only been made as a proof of concept and is not intended to ever be used in production.
Installation
pip install impexpr
Quickstart
impexpr alias can be used in the same way as python alias, a few examples:
- To run an interactive REPL with import expression support, run
impexpr - To run a script, run
impexpr script.py(all imported modules will also support import expressions) - To import itertools and use it in the same line:
for x in (import itertools).chain([1, 2], [3, 4], [5, 6]):
print(x)
- To get help about collections.deque:
help((import collections).deque)
- If your script must run with python alias but you want to enable import expression support in all imported modules (not in the main script!), you can use:
import impexpr
impexpr.add_hook()
# this will now support import expressions
import my_other_script
- For everything else, run
impexpr --help
FAQ
- Relative imports not supported yet
Metadata
Release files for impexpr 0.0.5
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 |
|---|---|---|---|---|
| impexpr-0.0.5.tar.gz | 3.7 kB | Without provenance | Details for impexpr-0.0.5.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| impexpr-0.0.5-py3-none-any.whl | Python 3 | none | any | Details for impexpr-0.0.5-py3-none-any.whl |
Total release size: 7.6 kB
Release files / impexpr-0.0.5.tar.gz
| Download URL | impexpr-0.0.5.tar.gz |
|---|---|
| Size | 3.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d3d615be56659c803111b6323ab84f18c970c6481083debab1f14cc1659f92da
|
|
BLAKE2b-256 checksum How to use checksums |
2338d457a69449c6c920e0536ae240235117ed265f75babd70e8605ac375d0cb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.1.13 CPython/3.10.4 Linux/5.15.38-1-MANJARO
|
Release files / impexpr-0.0.5-py3-none-any.whl
| Download URL | impexpr-0.0.5-py3-none-any.whl |
|---|---|
| Size | 3.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7955026450c662dadc57df5ebc6c9d5c60af92b9bc0830d5ecbb1fe1ef57479a
|
|
BLAKE2b-256 checksum How to use checksums |
c4174ee0f412f59becde86b939c55c44a10e7c88e1a73d97b5024ba49b07108c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.1.13 CPython/3.10.4 Linux/5.15.38-1-MANJARO
|
Security for impexpr 0.0.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.
To learn more about protecting yourself from malicious actors, visit our package security documentation.