An open API service indexing awesome lists of open source software.

https://github.com/erwinjanssen/dymport.py

Dynamically import (abitrary names from) arbitrary files in Python.
https://github.com/erwinjanssen/dymport.py

dynamic-import python python2 python3

Last synced: 8 months ago
JSON representation

Dynamically import (abitrary names from) arbitrary files in Python.

Awesome Lists containing this project

README

          

Dynamic import
==============

Sometimes you want to import some Python file by it's path only. This might
be a dynamically generated path, placing a __init__ in the directory might
not be an option. Maybe you are building some kind of plugin system, or want
to inject a dependency?

Dymport got you covered, it provides several function to import a file by path,
or import specific names from that file. It works on all major Python version,
providing a uniform interface for dynamically import arbitrary Python files.