ImportError: No module named _ssl
Did you build the Python from source? If so, you need the --with-ssl
option while building.
Python build finished, but the necessary bits to build these modules were not found
To be honest I would rather use a docker image for Python2 than try to compile it; might be overkill for some but for me it's the easier and cleaner way.
For example if you have a project
folder, containing at least project.py
and requirements.txt
you can use the following Dockerfile
(in the same folder as project
):
FROM python:2.7-slim-buster
COPY /project /app
RUN pip install --no-cache-dir -r /app/requirements.txt
WORKDIR /app
CMD [ "python", "project.py" ]
Build it with docker build -t project .
Run it with docker run -it --rm --name project_run project
Depending on how complex your application is you can also try to bring it up to date so it will run on Python 3 (there are also automated tools to help you with this).
Pyinstaller builds file but chokes on certain .dlls
Turns out this was an appJar/packaging issue, the pyinstaller was not looking in the correct directory for the assets. per the dev of appJar, I commented out two lines of code in the appJar.py, lines 508-509:
if self.platform == self.WINDOWS:
self.topLevel.wm_iconbitmap(self.appJarIcon)
More on the specifics here: https://github.com/jarvisteach/appJar/issues/84
I probably can fix this by using the --path argument with pyinstaller but for the moment, the issue is fully resolved
How to uninstall a package installed with pip install --user
Having tested this using Python 3.5 and pip 7.1.2 on Linux, the situation appears to be this:
pip install --user somepackage
installs to$HOME/.local
, and uninstalling it does work usingpip uninstall somepackage
.This is true whether or not
somepackage
is also installed system-wide at the same time.If the package is installed at both places, only the local one will be uninstalled. To uninstall the package system-wide using
pip
, first uninstall it locally, then run the same uninstall command again, withroot
privileges.In addition to the predefined user install directory,
pip install --target somedir somepackage
will install the package intosomedir
. There is no way to uninstall a package from such a place usingpip
. (But there is a somewhat old unmerged pull request on Github that implementspip uninstall --target
.)Since the only places
pip
will ever uninstall from are system-wide and predefined user-local, you need to runpip uninstall
as the respective user to uninstall from a given user's local install directory.
Related Topics
Add a Directory When Creating Tar Archive
Remove Strings by a Specific Delimiter
Use "Git Revert" to Back-Out a Change Adding a Line
Oracle Query - Ora-01652: Unable to Extend Temp Segment But Only in Some Versions of Sql*Plus
Go Memory Leak When Doing Concurrent Os/Exec.Command.Wait()
How to Concatenate Svg Files Lengthwise from Linux Command Line
How to Run an Image Windows Docker on Ubuntu
Downgrade R Version and R Package Bioconductor
Gatttool: Limited to 5 Connections
Starting Youtrack as a Service Fails Without Error Message
Skip Successfully Downloaded Files Using Wget
Is There Any Difference Between '=' and '==' Operators in Bash or Sh
Forcing a Context Switch from The Userland on Linux
How Convert Address in Elf to Physical Address
How to Replace The Word "Hello" with "Goodbye" in Every File in This Directory, and Also Recursively
Is It Efficient to Use Epoll with Devices (/Dev/Event/...)
How to Do "For Each" on Output from Find
Kaggle API Issue "Could Not Find Kaggle.JSON. Make Sure It's Located In......"