Openmc-plotter aborts on launch, AttributeError: 'MainWindow' object has no attribute 'shortcutOverlay'

I’ve installed openmc-plotter Version 0.4.0 on a SUSE Linux Enterprise Server 12 operating system, under Python 3.9. At first, this ran successfully and I was able to load-up one of the example geometries. However, upon quitting the app., I haven’t been able to start it again. It gets to the Reading plot XML file... stage and aborts with the following error:

Reading plot XML file...
Traceback (most recent call last):
   File "~/.conda/envs/plotter/bin/openmc-plotter", line 10, in <module>
     sys.exit(main())
   File "~/.conda/envs/plotter/lib/python3.9/site-packages/openmc_plotter/__main__.py", line 32, in main
     run_app(args)
   File "~/.conda/envs/plotter/lib/python3.9/site-packages/openmc_plotter/__main__.py", line 73, in run_app
     mainWindow.loadGui(use_settings_pkl=user_args.ignore_settings)
   File "~/.conda/envs/plotter/lib/python3.9/site-packages/openmc_plotter/main_window.py", line 99, in loadGui
     self.restoreWindowSettings()
   File "~/.conda/envs/plotter/lib/python3.9/site-packages/openmc_plotter/main_window.py", line 1072, in restoreWindowSettings
>     self.restoreState(settings.value("mainWindow/State"))
   File "~/.conda/envs/plotter/lib/python3.9/site-packages/openmc_plotter/docks.py", line 311, in resizeEvent
     self.main_window.resizeEvent(event)
   File "~/.conda/envs/plotter/lib/python3.9/site-packages/openmc_plotter/main_window.py", line 1158, in resizeEvent
     if self.shortcutOverlay.isVisible():
 AttributeError: 'MainWindow' object has no attribute 'shortcutOverlay'

… for any input I try, including the one that worked initially. Any ideas on how to debug?

@Chris If you have a plot_settings.pkl file in the directory you are running, try deleting that and then restarting the plotter.

Thanks for the quick response, but there’s no *.pkl file in this or the other directories. That’s why it’s so odd; it seems to be remembering a window configuration … but from where? I wondered if it related to the Qt GUI framework?

Further to the above; I deleted the Python environment in which openmc-plotter was installed and recreated it, but it still won’t launch. This makes me think there’s a cached settings file relating to the window software that needs deleting.

If openmc-plotter is not working due to the use of Qt another option is to try openmc_geometry_plot. It avoids the use of Qt by making a html based GUI.

https://github.com/fusion-energy/openmc_geometry_plot

Thanks Shimwell - I’ll give it a try. Any advice on how to install on an offline HPC system? I know how to do this via conda but not pip.