Skip to main content

noimport v0.0.1

A simple package to prevent the abusive use of the import statement in Python.

Installation

To install, just run:

pip install noimport

Usage

After importing the noimport package, any attempts of importation would result in an error

>>> import noimport
>>> import time			# Built in modules won't work, ...
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: import of time halted; None in sys.modules

>>> import foo			# ... nor local modules, ...
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'foo'

>>> import PIL			# ... nor pip installed packages
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'PIL'

License

This project is licensed under the MIT license


Python without modules and packages, how bad can it be?

Metadata

Release files for noimport 0.0.1

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

Source distribution (sdist)

Source distribution for noimport 0.0.1
File Size Uploaded
noimport-0.0.1.tar.gz 2.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for noimport 0.0.1
File Interpreter ABI Platform
noimport-0.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 4.8 kB

Release files / noimport-0.0.1.tar.gz

Download URL noimport-0.0.1.tar.gz
Size 2.0 kB
Tags Source
SHA-256 checksum
How to use checksums
6c6dfa0d387cd1d5086dca99c21c6e7f61143cafa1e28cf350fb30050afc006f
BLAKE2b-256 checksum
How to use checksums
c108d6db20ff70b8bcb7b68a2c21d2b8c8c3f783ae68772d6d5111d1e7e19c3a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.7.0 requests/2.22.0 setuptools/51.3.1 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.8.5

Release files / noimport-0.0.1-py3-none-any.whl

Download URL noimport-0.0.1-py3-none-any.whl
Size 2.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
402e174798bd0ca4b02ac1e1aaad16f0fea84b91da08e21bca202dfe8af0f6cb
BLAKE2b-256 checksum
How to use checksums
0325d0c199f8b4d13030b7944e95cc5170f463bc1b169485a408e88127bdf6a0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.7.0 requests/2.22.0 setuptools/51.3.1 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.8.5

Release history Release notifications | RSS feed

This release

0.0.1 This release

2 release files

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