Sorry I have a quick question if I was to import a package from a different file directory would that be possible to call how could I call it
Asked
Active
Viewed 23 times
1 Answers
0
If it's in a subfolder of your project folder, use:
from FOLDERNAME import thing
It selects the subfolder and chooses the module/package
OR Do so:
import sys
sys.path.insert(1, 'C:\\serverorsomething')
import app.folder.file
file.function()
This changes the imaginary directory for Python to import from.
Mikus Sturmanis
- 9
- 1