Skip to main content

Introduction

Import modules from anywhere on the file system.

Usage

import path_imports


# Import a certain file
foo_module = path_imports.import_from_path('somewhere/on your/file system/foo.py')

# Import a module from a certain directory
submodule = path_imports.import_from_directory('some/directory', 'root_module.submodule')

# Find the file path of a module
path = path_imports.find_module_location('my_module', directory='my project folder')
print(path)  # Output: "my project folder/my_module.py"

Installation

pip install path-imports

Documentation

There is no online documentation; however, the module has docstrings and type annotations. Your IDE should display all the relevant information to you.

Metadata

Release files for path-imports 1.1.2

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

Source distribution (sdist)

Source distribution for path-imports 1.1.2
File Size Uploaded Provenance Actions
path_imports-1.1.2.tar.gz 5.0 kB Without provenance Details for path_imports-1.1.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for path-imports 1.1.2
File Interpreter ABI Platform Actions
path_imports-1.1.2-py3-none-any.whl Python 3 none any Details for path_imports-1.1.2-py3-none-any.whl

Total release size: 9.7 kB

Release files / path_imports-1.1.2.tar.gz

Download URL path_imports-1.1.2.tar.gz
Size 5.0 kB
Tags Source
SHA-256 checksum
How to use checksums
0383a2d001664d1be00bdc25c2e98e52b5eaa9cd448f781f9c20f67e9c9eea75
BLAKE2b-256 checksum
How to use checksums
6f917fd45762f11a03a19d110212b9aa8e23ed61312b4cbfeeccc7359e3aec13
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.2

Release files / path_imports-1.1.2-py3-none-any.whl

Download URL path_imports-1.1.2-py3-none-any.whl
Size 4.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2472f6f814d4992088950f525ab6ee4e28aedcfe2375f23a874aa077bfb7a0cc
BLAKE2b-256 checksum
How to use checksums
46859e7cd66665d7c536b24f191ce5361d277f7ee06620c8200c09d6a7358cd2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.2

Security for path-imports 1.1.2

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