Skip to main content

English | 简体中文

preimport

Build Status Coverage Status Platform:win|osx|linux PyPI


preimport python modules to accelerate running speed and avoid "hang" when invoke module.

Installation

pip install preimport

Usage

from preimport import preimport

preimport('numpy', 'PyQt5')
preimport(['sys', 'os'])

It will be like following when using preimport in cli.

>>> # examples
>>> preimport('numpy')
>>> Preimporting 'numpy'       ...   successfully in 0.202s.
>>>
>>> # if module imported
>>> preimport('os')
>>> Preimporting 'os'        ...   [Note]:os already imported.
>>>
>>> # if module not installed
>>> preimport('PyQt5')
>>> Preimporting 'PyQt5'   ...   [Failed]:ModuleNotFound.
>>>
>>> # error module name
>>> preimport(1)
>>> [Error]: preimport error, moduleName must be str or Iterable.

Metadata

Release files for preimport 1.1.6

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

Built distribution (wheel)

Table of built distributions (wheels) for preimport 1.1.6
File Interpreter ABI Platform Actions
preimport-1.1.6-py2.py3-none-any.whl Python 2, Python 3 none any Details for preimport-1.1.6-py2.py3-none-any.whl

Release files / preimport-1.1.6-py2.py3-none-any.whl

Download URL preimport-1.1.6-py2.py3-none-any.whl
Size 12.6 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
036c182dd90958570882ed2dd445c6c114fd2921563b9e676407ae8bb6e6ac49
BLAKE2b-256 checksum
How to use checksums
8c690866fbfaacb2232df38bc39f78a4c761191ac89529ecbb7b3cddb1893e62
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.2

Security for preimport 1.1.6

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.

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