Mailing List Archive

ModuleNotFoundError: No module named 'Paramiko'
Dear Sir/Madam,

Recently I encounter a problem that I can't import paramiko in my computer. My PC running on window 10 64 bits. I have investigate this issue via internet, there are a lot of solutions for this issue, after trying most of the steps, I still can't run this module, the major steps I have try are:


1.
Install python ver 3.7.1 or 3.11.8 by itself or customer installation (changing the installation folder) and check add python to the path.
2.
pip install paramiko, if ver 3.7.1 installed, need to upgrade the pip version.
3.
Checking the environment path, there are two path related to the python, one for python.exe, the other for \Lib\site-packages\paramiko

can you please provide advice on this issue?



BR

Ken
--
https://mail.python.org/mailman/listinfo/python-list
Re: ModuleNotFoundError: No module named 'Paramiko' [ In reply to ]
pip may be pointed to another python version. try to remove other python
versions and re install pip

Regards,
*Sravan Chitikesi*
AWS Solutions Architect - Associate


On Mon, Apr 8, 2024 at 10:58?PM Wenyong Wei via Python-list <
python-list@python.org> wrote:

>
> Dear Sir/Madam,
>
> Recently I encounter a problem that I can't import paramiko in my
> computer. My PC running on window 10 64 bits. I have investigate this issue
> via internet, there are a lot of solutions for this issue, after trying
> most of the steps, I still can't run this module, the major steps I have
> try are:
>
>
> 1.
> Install python ver 3.7.1 or 3.11.8 by itself or customer installation
> (changing the installation folder) and check add python to the path.
> 2.
> pip install paramiko, if ver 3.7.1 installed, need to upgrade the pip
> version.
> 3.
> Checking the environment path, there are two path related to the python,
> one for python.exe, the other for \Lib\site-packages\paramiko
>
> can you please provide advice on this issue?
>
>
>
> BR
>
> Ken
> --
> https://mail.python.org/mailman/listinfo/python-list
>
--
https://mail.python.org/mailman/listinfo/python-list
Re: ModuleNotFoundError: No module named 'Paramiko' [ In reply to ]
To be sure, you can always go the the directory of the Python
interpreter and open a cmd window there.
(By entering 'cmd' into the explorer address bar.)
Then enter 'python.exe -mpip install paramiko'.
This way you can be sure that you're not running a pip.exe that belongs
to another Python interpreter.

--
https://mail.python.org/mailman/listinfo/python-list
Re: ModuleNotFoundError: No module named 'Paramiko' [ In reply to ]
On 4/8/2024 2:01 PM, Dietmar Schwertberger via Python-list wrote:
> To be sure, you can always go the the directory of the Python
> interpreter and open a cmd window there.
> (By entering 'cmd' into the explorer address bar.)
> Then enter 'python.exe -mpip install paramiko'.
> This way you can be sure that you're not running a pip.exe that belongs
> to another Python interpreter.

This is not quite right. The best name of the Python executable may or
may not be "python.exe". The command line needs a space after the "-m":

<python executable> -m pip install <package>

For <python executable>, you can check if "python" runs the intended
version by using the -V option (must be capitalized):

python -V

On Windows, Python from python.org usually installs a launcher named
"py", which will run the last version installed:

py -m pip install ...

Or it can run a specific version, e.g.:

py -3.7 -m pip install ...

This will run Python 3.7 if installed.

On Linux, you can run the desired version with, e.g.,

python3.7 -m pip ...
--
https://mail.python.org/mailman/listinfo/python-list
Re: ModuleNotFoundError: No module named 'Paramiko' [ In reply to ]
Thomas Passin <list1@tompassin.net> writes:
> On 4/8/2024 2:01 PM, Dietmar Schwertberger via Python-list wrote:
>> To be sure, you can always go the the directory of the Python
>> interpreter and open a cmd window there.
>> (By entering 'cmd' into the explorer address bar.)
>> Then enter 'python.exe -mpip install paramiko'.
>> This way you can be sure that you're not running a pip.exe that
>> belongs to another Python interpreter.
>
> This is not quite right. The best name of the Python executable may or
> may not be "python.exe". The command line needs a space after the
> "-m":

No, the option and its argument can be bundled. "-mpip" is equivalent
to "-m pip". (The space might make it clearer for human readers.)

[...]

--
Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com
Working, but not speaking, for Medtronic
void Void(void) { Void(); } /* The recursive call of the void */
--
https://mail.python.org/mailman/listinfo/python-list
Re: ModuleNotFoundError: No module named 'Paramiko' [ In reply to ]
On 4/8/2024 3:35 PM, Keith Thompson via Python-list wrote:
> Thomas Passin <list1@tompassin.net> writes:
>> On 4/8/2024 2:01 PM, Dietmar Schwertberger via Python-list wrote:
>>> To be sure, you can always go the the directory of the Python
>>> interpreter and open a cmd window there.
>>> (By entering 'cmd' into the explorer address bar.)
>>> Then enter 'python.exe -mpip install paramiko'.
>>> This way you can be sure that you're not running a pip.exe that
>>> belongs to another Python interpreter.
>>
>> This is not quite right. The best name of the Python executable may or
>> may not be "python.exe". The command line needs a space after the
>> "-m":
>
> No, the option and its argument can be bundled. "-mpip" is equivalent
> to "-m pip". (The space might make it clearer for human readers.)

Oh, surprise, thanks for the correction. My apologies to Dietmar. I'd
stick with the space, though, because it's often required by other
programs. No sense developing a conflicting habit...

--
https://mail.python.org/mailman/listinfo/python-list
Re: ModuleNotFoundError: No module named 'Paramiko' [ In reply to ]
On 4/7/24 19:31, Wenyong Wei via Python-list wrote:
>
> Dear Sir/Madam,
>
> Recently I encounter a problem that I can't import paramiko in my computer. My PC running on window 10 64 bits. I have investigate this issue via internet, there are a lot of solutions for this issue, after trying most of the steps, I still can't run this module, the major steps I have try are:
>
>
> 1.
> Install python ver 3.7.1 or 3.11.8 by itself or customer installation (changing the installation folder) and check add python to the path.
> 2.
> pip install paramiko, if ver 3.7.1 installed, need to upgrade the pip version.
> 3.
> Checking the environment path, there are two path related to the python, one for python.exe, the other for \Lib\site-packages\paramiko
>
> can you please provide advice on this issue?

Going to be more explicit than the other answers:

===
If an attempted import gives you ModuleNotFound, that *always* means the
package is not installed... not at all, or just not in the paths that
copy of Python is looking in.
===

The problem arises in part because most package installation
instructions take the simplest approach and just tell you to (for example)

pip install paramiko

So it's installed. But where did it go? You can check where it went:

pip show paramiko

That path ("location") needs to be one where your Python interpreter is
looking.

If all goes well, "pip" and "python" are perfectly matched, but in the
current world, there are often several Python interpreters installed
(projects may require a specific version, an IDE may grab its own
version, something may create and setup a virtualenv, alternate worlds
like Conda may set up a Python, the list goes on), and for any given
installation on Windows, python.exe and the pip excutable pip.exe go in
different directories anyway, and the Windows PATH doesn't always
include both, and you easily get mismatches.

As others have said, the way to avoid mismatches is to use pip As A
Module, specifically a module of the Python you want to use. So if
you're using the Python Launcher, that looks like:

py -m pip install paramiko

Hope this helps.

--
https://mail.python.org/mailman/listinfo/python-list
Re: ModuleNotFoundError: No module named 'Paramiko' [ In reply to ]
hi Sravan,

Thanks for your response, checked and found there is only one python in my PC.



________________________________
From: Sravan Kumar Chitikesi <sravan.chitikesi@iprotechs.com>
Sent: Tuesday, 9 April 2024 3:42 AM
To: Wenyong Wei <weijiawenyong@hotmail.com>
Cc: python-list@python.org <python-list@python.org>
Subject: Re: ModuleNotFoundError: No module named 'Paramiko'

pip may be pointed to another python version. try to remove other python versions and re install pip

Regards,
Sravan Chitikesi
AWS Solutions Architect - Associate


On Mon, Apr 8, 2024 at 10:58?PM Wenyong Wei via Python-list <python-list@python.org<mailto:python-list@python.org>> wrote:

Dear Sir/Madam,

Recently I encounter a problem that I can't import paramiko in my computer. My PC running on window 10 64 bits. I have investigate this issue via internet, there are a lot of solutions for this issue, after trying most of the steps, I still can't run this module, the major steps I have try are:


1.
Install python ver 3.7.1 or 3.11.8 by itself or customer installation (changing the installation folder) and check add python to the path.
2.
pip install paramiko, if ver 3.7.1 installed, need to upgrade the pip version.
3.
Checking the environment path, there are two path related to the python, one for python.exe, the other for \Lib\site-packages\paramiko

can you please provide advice on this issue?



BR

Ken
--
https://mail.python.org/mailman/listinfo/python-list
--
https://mail.python.org/mailman/listinfo/python-list