pythonpath Questions

10

Solved

How do I find out which directories are listed in my system’s PYTHONPATH variable, from within a Python script (or the interactive shell)?
Selmaselman asked 28/9, 2009 at 22:1

2

Solved

I created a virtualenv in my django app folder, and there I installed all my python dependencies. My Django project is called theme, so in the theme folder there is a venv folder that contains the ...
Jessen asked 20/6, 2012 at 2:14

3

Solved

I'm writing a family of Python scripts within a project; each script is within a subdirectory of the project, like so: projectroot | |- subproject1 | | | |- script1.main.py | `- script1.merge...
Briarwood asked 6/8, 2013 at 17:53

4

Solved

I'm trying to serve a little django project with the following Apache configuration : Apache virtualhost configuration : <VirtualHost *> ServerName servername [...] <Directory "/pat...
Hayrick asked 4/8, 2016 at 1:9

11

I am using IntelliJ with the Python plugin and the Remote Interpreter feature to communicate with my Vagrant VM. It sets up the remote interpreter correctly to use my VM's interpreter. But, I use a...
Currin asked 19/6, 2013 at 18:10

4

My imports don't work when I try to run the code from Linux terminal. Specifically, imports from other packages in the same project. I know this is a PYTHONPATH issue, but I don't know how to diagn...
Plante asked 30/1, 2018 at 23:28

0

If you launch a Python process either as a single command from the command line (with the -c flag) or by specifying a module path (with the -m flag), the working directory is prepended to sys.path....
Ore asked 26/11, 2020 at 15:10

5

I want to ask you something that came to my mind doing some stuff. I have the following structure: src - __init__.py - class1.py + folder2 - __init__.py - class2.py I class2.py I want to i...
Leena asked 26/9, 2018 at 11:37

7

Solved

Consider the following Python project skeleton: proj/ ├── foo │   └── __init__.py ├── README.md └── scripts └── run.py In this case foo holds the main project files, for example # foo/__init__...
Romaine asked 1/9, 2019 at 8:38

5

Solved

I recently added some things to my python path that I don't want there using: export PYTHONPATH=$PYTHONPATH:/my/path You can use sys.path.remove to remove something in the path, but it's not 100...
Anguilla asked 8/10, 2013 at 19:16

7

Solved

In development mode, I have the following directory tree : | my_project/ | setup.py | my_project/ | __init__.py | main.py | conf/ | myproject.conf I use ConfigParser to parse the myproject.c...
Cuevas asked 27/9, 2011 at 10:27

2

Solved

If I type in which python I get: /home/USER/anaconda3/bin/python If I type in echo $PYTHONPATH I get: /home/USER/terrain_planning/devel/lib/python2.7/dist-packages:/opt/ros/melodic/lib/python2.7/di...
Councilman asked 11/2, 2020 at 8:29

6

Solved

Another developer and I disagree about whether PYTHONPATH or sys.path should be used to allow Python to find a Python package in a user (e.g., development) directory. We have a Python project with ...
Stature asked 12/12, 2009 at 14:33

0

Let's say we have two different Python packages from the same vendor, named with the same name -- foo. One is installed with pip and can be found in the /usr/lib/python/site-packages/foo directory,...
Burgoyne asked 26/11, 2019 at 13:21

3

I don't know very much about python but would like to install some python modules in a local directory on a server on which I don't have sudo access. I start by going into my desired directory (no...
Quelpart asked 14/3, 2015 at 3:38

3

Solved

Yesterday, I edited the bin/activate script of my virtualenv so that it sets the PYTHONPATH environment variable to include a development version of some external package. I had to do this because ...
Coriander asked 1/2, 2013 at 13:26

4

Solved

I want to add a specific library path only to python2. After adding export PYTHONPATH="/path/to/lib/" to my .bashrc, however, executing python3 gets the error: Your PYTHONPATH points to a site-pack...
Supplementary asked 3/12, 2015 at 12:35

3

Solved

I have 4 directories: /home/user/test1 /home/user/test2 /home/user/test3 /home/user/test4 I have another directory with tests /home/user/testing having the file testall.py ow, how can I appe...
Blowgun asked 15/5, 2012 at 19:38

6

Solved

EDIT: Works for root, sudo is the problem. Read below. I have a directory with my own libraries, e.g. my Python libraries are located at /home/name/lib/py. I've added this directory to Python's PA...
Ney asked 1/11, 2011 at 16:23

4

Solved

I know how to install packages in Anaconda using conda install and also how to install packages that are on PyPi which is described in the manual. But how can I permanently include packages/folders...
Calcicole asked 3/5, 2016 at 13:49

4

On my system, I have several modules installed multiple times. To give an example, numpy 1.6.1 is installed in the standard path at /usr/lib/python2.7/dist-packages, and I have an updated version o...
Mock asked 23/5, 2014 at 15:8

6

Solved

debian@debian:~$ echo $PYTHONPATH /home/qiime/lib/: debian@debian:~$ python Python 2.7.3 (default, Jan 2 2013, 16:53:07) [GCC 4.7.2] on linux2 Type "help", "copyright", "credits" or "license" ...
Vernon asked 29/4, 2013 at 1:12

5

I am trying to install a package called "simpleguitk" via pip. (On Ubuntu 16.04 with Python 3.5) After running sudo -H pip3 install simpleguitk it says installation is completed successfully. (...
Riehl asked 27/11, 2016 at 22:27

0

I'm working on a project using Python(3.6) and Django(2) in which I need to read all the text files from a directory one by one, I have written the code but it is reading only 28 files from a folde...
Nada asked 11/12, 2018 at 7:27

2

Solved

I want to set up PyCharm to work on a set of Python projects in a single window. Lets say I have this projects structure. ~/src ├── py_project1 ├── py_project2 ├── py_project3 ├── other_lang_proj1 ...
Injector asked 16/12, 2015 at 18:46

© 2022 - 2025 — McMap. All rights reserved.