import problem on portable variant

48 views
Skip to first unread message

Pascal Rousset

unread,
Mar 4, 2023, 10:07:28 PM3/4/23
to thonny
Hi
On the portable variant even if a plugin is installed (example pyserial), the import of the latter does not work ( import pyserial > ModuleNotFoundError: No module named 'pyserial' ). portable variant with 64-bit Python 3.10
Can you help me please ?

Cordially

Aivar Annamaa

unread,
Mar 12, 2023, 10:00:49 AM3/12/23
to thonny
1) A Thonny plug-in is meant for Thonny, i.e. it is not something you are supposed to import in your programs. 
2) The distribution package "pyserial" provides a module named "serial", not "pyserial".

Best regards,
Aivar

Pascal Rousset

unread,
Mar 12, 2023, 6:22:58 PM3/12/23
to thonny
Thank you for your two responses. 
For Pyserial you are correct; I made a confusion between package and module. That works.

Now my problem concerns other modules not installed as a base like for example pandas. The installation goes well but then impossible to import pandas (No module named 'pandas').
The problem does not arise with Thonny installed but only with portable Thonny.
Best regards,
Pascal ROUSSET

Aivar Annamaa

unread,
Mar 13, 2023, 4:07:38 PM3/13/23
to thonny
Are you sure you used "Tools => Manage packages" and not "Tools => Manage plug-ins"? Make sure you read the note on top of "Manage plug-ins" dialog.

Best regards,
Aivar

Pascal Rousset

unread,
Mar 15, 2023, 7:59:45 PM3/15/23
to thonny
Indeed, it works ! Thank you
Reply all
Reply to author
Forward
0 new messages