7,530 questions
Advice
0
votes
6
replies
77
views
How to import an editable package?
I've installed a package from a cloned repository, in "editable" mode (pip install -e .). I can't import the package in a script in the virtual environment where the package in installed (...
Advice
0
votes
7
replies
97
views
Is it possible to auto select a Python venv without using the terminal or VSCode?
Ok so I am the only technical person at a non-technical company. I am writing some scripts that I will be disseminating to my team. My goal is for everyone else on the team to be able to right click ...
Advice
0
votes
2
replies
66
views
Vim 9.1 & Python Virtual Env
I'm writing vim-script(s) that utilizes vim's embedded Python environment. One of these requires the Python Environment to utilize a virtual environment. Ideally for this application, vim would ...
0
votes
0
answers
57
views
How to safely fix and migrate pip3 packages installed and run using sudo/root/local users to a safe pip3 virtual environment (venv)?
I am running an Ubuntu 24.04 Lemp Server, and I'm not sure I fully understand pip3 and how it works. When installing certain python3-pip packages, some of them required being installed and run as root ...
1
vote
1
answer
86
views
python virtualenv without losing apt-installed modules
How can I create a python Virtual ENVironment (venv) such that the new venv has all of the python modules that are already installed on my system (with apt)?
🛈 Note: It's much more secure to install ...
0
votes
0
answers
54
views
Confusion about virtual environment and kernels in jupyter notebook
I created a virtual environment called "fastai" by conda. I tried to install ipywidgets in it by
mamba install ipywidgets
Then I checked it and it did exist. But when I used
jupyter --...
0
votes
0
answers
108
views
Installing virtualenv globally with Homebrew
I am trying to build someone else's project that relies on the virtualenv package. On Mac OS with Homebrew, the python environment is externally managed, so I can't "globally" install ...
0
votes
2
answers
1k
views
Best way to create a Python virtual environment with a higher Python version than the global version?
I work on a computing cluster. The global Python version on the node is 3.8. I have a virtual environment that I use when I start a job. The cluster uses LSF for scheduling. I usually access it via ...
1
vote
1
answer
83
views
Using moviepy fails due to "ModuleNotFoundError: No module named 'pip._internal.utils.temp_dir'" SOLVED
These are the errors when I attempt to run my application:
Traceback (most recent call last):
File "<frozen runpy>", line 198, in _run_module_as_main
File "<frozen runpy>...
-1
votes
1
answer
67
views
Problem activating my env using django with python in vscode [duplicate]
env\Scripts\activate when I want to activate my env they saying I can't cause the execution of the script its disabled
and its happens to me with every file in my django folder (except the html ...
2
votes
2
answers
145
views
Is there a way to automate activating the virtualenv in Powershell (in Windows)?
I know that to activate virtualenv it's just .venv/Scripts/activate.ps1 but I was wondering if there's a way of having powershell do it automatically?
Existing ones just talk about activating it, but ...
1
vote
1
answer
134
views
Poetry Install broken, ModuleNotFoundError but Module is installed. MacOS
After cloning and setting up my repo I use a poetry install
When running the code, I see
ModuleNotFoundError: No module named 'loguru'
The package is there however:
poetry add loguru
The following ...
0
votes
1
answer
74
views
When using venv, packages I'm building suddenly disappear when others are installed
This is more of a where in pip could this be happening, not a question about the repos/packages.
I'm building several pytorch related repos using their setup.py scripts. For example, https://github....
0
votes
0
answers
73
views
pre-commit is failing due to virtualenv
pre-commit is failing on all invocations due to an upstream dependency failure with virtualenv. I get the following error:
[INFO] Initializing environment for https://github.com/pre-commit/pre-commit-...
0
votes
1
answer
83
views
Is it possible to use the same virtualenv in MWAA with PythonVirtualenvOperator?
I have a few DAGs that needs to run in a certain time that takes almost all the time-window it has to run before the next process is triggered.
Adding the overhead of installing packages on every ...
0
votes
1
answer
402
views
How can I reuse the same virtualenv in a different project?
I have created a project folder with a pyproject.toml, but I want to use the same virtualenv created in the ProjectA in ProjectB, how can I do that ?
Whenever I use the poetry env use /full/path/...
2
votes
2
answers
96
views
VSCode and Python virtualenv troubles
I have 2 problems. Here was my set-up. I have all of my respositories in ~/dev/, and I had all of my Python virtualenvs in ~/virtualenvs/. This worked OK, but one annoying thing was that it was ...
-1
votes
1
answer
114
views
How do I change the Base path and executables for poetry env
When I run
poetry run python manage.py runserver
in my django backend I get this error
ImportError: cannot import name 'GenericAPIView' from 'rest_framework.views'
I think it is related to my poetry ...
0
votes
0
answers
24
views
Package recognition problem in a venv containing multiple .git directories
Python has a trouble recognizing packages. This is my current setting:
Project
|_ .venv
|_ repo1
|_ .git
|_ setup.py
|_ repo1
|_ __init__.py
|_ repo1.py
|_ other ...
0
votes
0
answers
45
views
Cloudera Data Science Workbench Not Using Virtual Environment's Python
Question:
I am working in Cloudera Data Science Workbench (CDSW) and have created a virtual environment named "testenv". I started a session and activated my virtual environment using:
...
1
vote
1
answer
77
views
Python3 venv version AND system version?
Mac Mini M1.
Hi,
I am trying to setup Google Calendar API. I followed every step explained in ...see documentation
When running the quickstart.py script given as sample (see here) I got errors :
...
3
votes
2
answers
619
views
Distinction between Python environment and Jupyter kernel in VS Code
In Python I can create a virtual environment in VS Code with the following commands, I'll also install a kernel to the same virtual environment:
python3 -m venv .venv
source .venv/bin/activate
pip ...
1
vote
1
answer
347
views
Jupyter gives 404 errors on Debian and I'm unable to open any notebook
I'm currently unable to use jupyter on my Dell laptop that runs Debian 12. I'm running jupyter lab in a python virtualenv.
When I run jupyter lab I first get the following error message that is ...
0
votes
0
answers
276
views
pyenv(1): OSError: [Errno 13] Permission denied: '/usr/local/lib/python3.11'
On a fresh install of Fedora-41 with pyenv(1) setup as shown, when I execute user@fedora$ pyenv install 3.11.11, I receive the exception shown. I think this comes from the internal Python installation ...
1
vote
2
answers
283
views
How to make pip virtual environments truly portable?
I'm trying to install Open WebUI as a portable installation, where the base folder can be moved or renamed. However, I've encountered issues making the virtual environment truly portable.
While ...