Skip to content

fix: instantiate QApplication for test_Parameter.py#2539

Merged
j9ac9k merged 1 commit intopyqtgraph:masterfrom
pijyoi:fix-test-parameter-standalone
Nov 26, 2022
Merged

fix: instantiate QApplication for test_Parameter.py#2539
j9ac9k merged 1 commit intopyqtgraph:masterfrom
pijyoi:fix-test-parameter-standalone

Conversation

@pijyoi
Copy link
Copy Markdown
Contributor

@pijyoi pijyoi commented Nov 26, 2022

As test_Parameter.py instantiates some gui elements, it needs QApplication to have been instantiated. When this test is run alone, it will segfault. i.e. it was relying on other tests in the test-suite having instantiated QApplication.

from functools import wraps

import numpy as np
import pyqtgraph as pg

Check notice

Code scanning / CodeQL

Module is imported with 'import' and 'import from'

Module 'pyqtgraph' is imported with both 'import' and 'import from'.
@j9ac9k
Copy link
Copy Markdown
Member

j9ac9k commented Nov 26, 2022

Nice catch @pijyoi ! LGTM, merging

@j9ac9k j9ac9k merged commit c983f37 into pyqtgraph:master Nov 26, 2022
@pijyoi pijyoi deleted the fix-test-parameter-standalone branch November 26, 2022 20:50
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

Successfully merging this pull request may close these issues.

2 participants