I am downloading an old school project in preparation for a job interview and I am trying to run it on PyCharm. I originally used an environment of Python 2.7 and although I do still have 2.7 installed I am running Python 3 on current projects.
When I try to open the project, I am getting an alert saying I need to set my configuration. When I tried to add an interpreter, it tells me that my SDK seems invalid and gives me error 13 (permissions denied).
I have tried following the solution suggested here (PyCharm error: [Errno 13] Permission denied)
to fix the root permissions, and that didn't work. I uninstalled Python 2.7 and tried to remove any references to it, but that hasn't worked either. I am so incredibly confused, any help in the right direction would be very appreciated.
Related
I do not know what happened, but suddenly I can no longer run Python code like before. I am on windows and I have a feeling the problem is the result of PATH, because I have seen this error before.
Python gives me the following error when trying to import matplotlib:
ImportError: cannot import name 'axes' from 'matplotlib'
(C:\Users\JohnDoe\AppData\Local\Packages
\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\
Python310\site-packages\matplotlib\__init__.py)
When trying to install matplotlib, I get the following error:
ERROR: Could not install packages due to an OSError: [WinError 5]
Toegang geweigerd: 'C:\\Users\\JohnDoe\\AppData\\Local\\Packages
\\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\\LocalCache\\local-packages
\\Python310\\site-packages\\matplotlib\\ft2font.cp310-win_amd64.pyd'
Check the permissions.
My setup:
Windows 11
VS Code installed through the MS Store
Python installed through VS Code, which also installs python through the MS Store
I managed to solve this issue. For future reference, the solution was:
Run pip list, take note of every package starting with ~ and where the first letter is missing (example ~atplotlib instead of matplotlib). The location of the directory is also shown.
Open the location as indicated by pip list in a file explorer, find the package starting with a ~ and delete the folder.
The command pip install matplotlib and pip install --user matplotlib still create a OSerror stating the permission is denied. This error occurs both in the terminal of VS Code, command prompt and command prompt opened as administrator.
The solution to the OSerror is to run VS Code as administrator and then run pip install matplotlib from the terminal in VS Code.
To summarize: delete the conflicting package and reinstall through the VS Code terminal while running VS Code as administrator.
All other suggestions I found online to solve this issue failed for me. These suggestions included changing the permission in windows to full access.
Trying to install python extension for vscode but i always encounter an error.
by the way, python 3.10.9 is installed on my pc and works correctly
i tried installing it from the vscode editor but encounterd an error
i downloaded the vsix file using 2 different PCs but that too i always lebeled as corrupt
picture is below
any ideas pleaseenter image description here
After trying for a hours, i got the solution to my case.
for me, the internet connection was slow and caused interuptions in the installation.
I realise this when i got a stronger internet connection and the extension installed properly and without any suffering.
I was cleaning out my laptop and somehow screwed up my Python installation. Now I'm getting an error that I can't even find the answer to in Google (I usually copy and paste the error msg as a Google search and it usually leads me to an answer on here or other sites). This is the error msg verbatim: Fatal error in launcher: Unable to create process using '"C:\Python310\python.exe" "C:\Python310\Scripts\pip.exe" install Flask': The system cannot find the file specified.
I just reinstalled Python 3.10 via the installer from the Python site (so as not to screw up with Linux install since it likes to auto install 2.7 for some reason)
Any help would be greatly appreciated as always
Not sure what's gone wrong here. I upgraded pip before installing the python-docx module and though it gave me that error, the version changed so I wasn't sure what had gone wrong. My site-packages are red which I read means that they're excluded, but I'm not sure what that means for this instance. I've got a screenshot of what's going down in both cmd and pycharm:
Try Running cmd as administrator, Clearly it says "Access Denied". Are you logged in on an Admin user Account in Windows?
Try Right Clicking and open the CMD with Admin Privileges.
The problem is that you have 2 runtime of python.
Lets call them A and B.
You have installed the external lib under runtime A but you try to consume it under runtime B.
A - is under "AppData"
B - is "venv"
I'm trying to update Anaconda using conda update --all.
I receive the following warning:
Warning: 2 possible package resolutions (only showing differing packages):
- anaconda::navigator-updater-0.2.1-py36_0
- defaults::navigator-updater-0.2.1-py36done
Then it begins:
## Package Plan ##
environment location: /Users/me/anaconda3
...Followed by all sorts of good things. The transaction is then prepared, verified and executed, after which I get the following errors:
ERROR conda.core.link:_execute(700): An error occurred while uninstalling package 'https://repo.continuum.io/pkgs/main/osx-64/xlrd-1.1.0-py36h336f4a2_1.tar.bz2::xlrd-1.1.0-py36h336f4a2_1'.
Rolling back transaction: done
[Errno 13] Permission denied: '/Users/me/anaconda3/lib/python3.6/site-packages/xlrd/__init__.py' -> '/Users/me/anaconda3/lib/python3.6/site-packages/xlrd/__init__.py.c~'
()
Being the newer coder that I am, I have no idea about the environment or what it takes to update this beyond monkey-typing in what I've been told to do. What the heck do these mean and how do I solve them? I would imagine that updating would be simple, as it is going back to the folder that it came from, so why is it saying there there is an Error 13 which, as my research seems to indicate, is an admin privileges issue? (I am admin on my machine, using a Mac with interactive shell zsh.)
So it seems like the version of conda that you are using was prone to these errors. Searching it up brings up a multitude of similar errors and the common solution is to always update conda, just like you tried.
From #soapy1 comment from here, states that:
Looks like this is fixed on master, it should be resolved in the next release of conda
My advice would be, if possible, uninstall and install anaconda. This will install with the latest packages and the error shouldn't persist. You should follow the documentation on doing this safely.