Ask Your Question
1

matplotlib Ver 3.3.3 from Python Shell - <solved>

asked 2020-12-04 03:10:46 -0500

iain1940 gravatar image

updated 2020-12-05 03:30:50 -0500

I'm having problems using Matplotlib on Linux Mint 20 (Ubuntu 20.04) from the python Shell

Traceback (most recent call last): Python Shell, prompt 1, line 967

builtins.AttributeError: partially initialized module 'matplotlib' has no attribute '__path__' (most likely due to a circular import)

During handling of the above exception, another exception was raised:

Traceback (most recent call last):

Runs program OK from green triangle

Iain

edit retag flag offensive close merge delete

Comments

I'm able to run a simple example on ubuntu 20.10 with the system provided python & matplotlib and also matplotlib 3.3.3 installed via pip. What versions of Wing and python are you using? Also what code are you running in the Python Shell?

Wingware Support gravatar image Wingware Support  ( 2020-12-04 10:25:40 -0500 )edit

I'm running Python 3.8.5 and WingPro 7.2.7.0

'import matplotlib' is the only command in the Python Shell.

The problem is comparatively minor as I am using scripts for almost all my work. The question was started before I realised that scripts worked OK.

Iain

iain1940 gravatar image iain1940  ( 2020-12-04 12:01:03 -0500 )edit

Could you send the full traceback and exception to support@wingware.com?

Wingware Support gravatar image Wingware Support  ( 2020-12-04 17:13:29 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
1

answered 2020-12-05 03:30:31 -0500

iain1940 gravatar image

updated 2020-12-05 03:32:13 -0500

Problem Solved. There was a file "matplotlib.py" in the current folder dating back to 2018 ! (the last time I played with matplotlib) which contained the line "import matplotlib.pyplot as plt"

Apologies - I should have examined the error message more carefully before suspecting other peoples software !

During handling of the above exception, another exception was raised: Traceback (most recent call last): Python Shell, prompt 1, line 1 # Used internally for debug sandbox under external interpreter
File "/home/**/winglets/matplotlib.py", line 8, in <module> import matplotlib.pyplot as plt builtins.ModuleNotFoundError: No module named' matplotlib.pyplot'; 'matplotlib' is not a package

edit flag offensive delete link more

Comments

Thanks for letting us know and don't hesitate to contact us when you run into problems.

Wingware Support gravatar image Wingware Support  ( 2020-12-07 10:06:45 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

2 followers

Stats

Asked: 2020-12-04 03:10:46 -0500

Seen: 123 times

Last updated: Dec 05 '20