-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Running tuneconfig() in IPython console results in Attribute Error (v.2.2.1) #58
Comments
This I think has been fixed. Please check diffpy-users group for
discussion
S
…On Wed, May 31, 2023 at 11:08 AM p3rAsperaAdAstra ***@***.***> wrote:
General Info
OS: Windows 10
Python: 3.8
pdfgetx3: 2.2.1
The error occurse when:
Running tuneconfig() in IPython console
List of commands run:
Ran:
pdfgetx3 myfile.xy --plot=gr,fq,sq
Returns:
Installed qt5 event loop hook.
Shell is already running a gui event loop for qt5. Call with no arguments
to disable the current loop.
Using matplotlib backend: QtAgg
Ran:
tuneconfig()
Returns:
This is where the error occurs. It opens up the tuneconfig window, but it
remains blank/white.
Traceback:
File diffpy/pdfgetx/pdfgetxapplication.py:279, in tuneconfig(self,
plotids, pdfgetter, axeslist)
File diffpy/pdfgetx/tuneconfig.py:518, in createTuneConfig(pdfgetter,
**kwargs)
File diffpy/pdfgetx/tuneconfig.py:123, in *init*(self, pdfgetter,
plotids, axeslist, *reset_init*)
File diffpy/pdfgetx/tuneconfig.py:211, in _makeGUIFigure(self)
AttributeError: 'FigureCanvasQTAgg' object has no attribute
'set_window_title'
So I'm guessing that the issue is the use of the QtAgg backend? I have
found an issue while googling that looks like it might hold the explanation
for this error:
matplotlib/matplotlib#17716
<matplotlib/matplotlib#17716>
The solution in that case seems to be to just not include the
'set_window_title' command.
I do not know much about Qt, but it seems like the whole thing crashes
simply because the tuneconfig window title is being set to the string
"tuneconfig" and the Canvas Class doesn't recognize that method.
Was that method renamed in a different version of Qt? Does tuneconfig
really need a title? Do I just need to change the version of one of my
python libs?
[image: image]
<https://user-images.githubusercontent.com/60529579/242239438-0b1df48d-7a21-4fc8-a024-35f177dd8136.png>
—
Reply to this email directly, view it on GitHub
<#58>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABAOWUPLNVT74LEEBJ3EB4TXI4KCLANCNFSM6AAAAAAYVHDDL4>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
--
Simon Billinge
Professor, Columbia University
|
Ok so just for posterity if someone doesn't know about the google group: This is the link to the relevant issue in the Google Group: If you wish to downgrade you matplotlib version to one that will work, use: Best option is to create a virtual environment first using virtualenv and then installing the right matplotlib version as noted above. Everything worked perfectly the moment I downgraded to matplotlib 3.4 |
General Info
OS: Windows 10
Python: 3.8
pdfgetx3: 2.2.1
The error occurse when:
Running tuneconfig() in IPython console
List of commands run:
Ran:
pdfgetx3 myfile.xy --plot=gr,fq,sq
Returns:
Installed qt5 event loop hook.
Shell is already running a gui event loop for qt5. Call with no arguments to disable the current loop.
Using matplotlib backend: QtAgg
Ran:
tuneconfig()
Returns:
This is where the error occurs. It opens up the tuneconfig window, but it remains blank/white.
Traceback:
File diffpy/pdfgetx/pdfgetxapplication.py:279, in tuneconfig(self, plotids, pdfgetter, axeslist)
File diffpy/pdfgetx/tuneconfig.py:518, in createTuneConfig(pdfgetter, **kwargs)
File diffpy/pdfgetx/tuneconfig.py:123, in init(self, pdfgetter, plotids, axeslist, reset_init)
File diffpy/pdfgetx/tuneconfig.py:211, in _makeGUIFigure(self)
AttributeError: 'FigureCanvasQTAgg' object has no attribute 'set_window_title'
So I'm guessing that the issue is the use of the QtAgg backend? I have found an issue while googling that looks like it might hold the explanation for this error:
matplotlib/matplotlib#17716
The solution in that case seems to be to just not include the 'set_window_title' command.
I do not know much about Qt, but it seems like the whole thing crashes simply because the tuneconfig window title is being set to the string "tuneconfig" and the Canvas Class doesn't recognize that method.
Was that method renamed in a different version of Qt? Does tuneconfig really need a title? Do I just need to change the version of one of my python libs?
The text was updated successfully, but these errors were encountered: