Skip to content
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

Error in construction of QApplication before QWidget. #1310

Open
reneela opened this issue Oct 10, 2024 · 0 comments
Open

Error in construction of QApplication before QWidget. #1310

reneela opened this issue Oct 10, 2024 · 0 comments

Comments

@reneela
Copy link

reneela commented Oct 10, 2024

There is a issue about running "phy template-gui params.py" in the phy2 environment that I created. And it returns the error as shown in the screen shot. We had already tried to run the command "pip install PyQtWebEngine" and try launching phy again. But it can't work. Could you pleas help us to solve this problem? Thank you very much.

phy template-gui params.py --debug returns this:
`(phy2) C:\Users\hengj\OneDrive\Desktop\Kilosort_2023-10-24_155303>phy template-gui params.py --debug
17:17:20.505 [D] init:68 Start capturing exceptions.
17:17:20.510 [E] init:62 An error has occurred (OSError):
Traceback (most recent call last):
File "", line 198, in _run_module_as_main
File "", line 88, in run_code
File "C:\Users\hengj\anaconda3\envs\phy2\Scripts\phy.exe_main
.py", line 7, in
sys.exit(phycli())
^^^^^^^^
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\click\core.py", line 1157, in call
return self.main(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\click\core.py", line 1078, in main
rv = self.invoke(ctx)
^^^^^^^^^^^^^^^^
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\click\core.py", line 1688, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\click\core.py", line 1434, in invoke
return ctx.invoke(self.callback, **ctx.params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\click\core.py", line 783, in invoke
return _callback(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\click\decorators.py", line 33, in new_func
return f(get_current_context(), *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\phy\apps_init
.py", line 159, in cli_template_gui
template_gui(params_path, **kwargs)
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\phy\apps\template\gui.py", line 209, in template_gui
model = load_model(params_path)
^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\phylib\io\model.py", line 1440, in load_model
return TemplateModel(**get_template_params(params_path))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\phylib\io\model.py", line 339, in init
self._load_data()
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\phylib\io\model.py", line 348, in _load_data
self.spike_samples, self.spike_times = self._load_spike_samples()
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\phylib\io\model.py", line 652, in _load_spike_samples
times = self._read_array(times_path)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\hengj\anaconda3\envs\phy2\Lib\site-packages\phylib\io\model.py", line 487, in _read_array
raise IOError()
OSError

QWidget: Must construct a QApplication before a QWidget
`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant