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

Fix QSettings initialization failure on startup when parsing invalid arguments #360

Merged
merged 1 commit into from
Jan 14, 2024

Conversation

pablomartin4btc
Copy link
Contributor

@pablomartin4btc pablomartin4btc commented Aug 31, 2023

This fixes #361.

After applying the fix, no QML source code errors should be displayed on the terminal:

image

@pablomartin4btc pablomartin4btc marked this pull request as ready for review August 31, 2023 20:09
@hebasto hebasto changed the title qml: Fix QSettings initialization failure on startup when parsing invalid arguments Fix QSettings initialization failure on startup when parsing invalid arguments Aug 31, 2023
@hebasto
Copy link
Member

hebasto commented Aug 31, 2023

@pablomartin4btc pablomartin4btc force-pushed the fix-QSetting-init branch 2 times, most recently from a522ca5 to fb7b225 Compare August 31, 2023 23:28
Moving bitcoin.cpp app setters before parsing
command-line options; otherwise if invalid
parameters are passed, QSetting initialization
would fail and the corresponding error will be
displayed on terminal.
@pablomartin4btc
Copy link
Contributor Author

Rebased.

Copy link
Contributor

@MarnixCroes MarnixCroes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tested e1b0798 lgtm

Copy link
Contributor

@D33r-Gee D33r-Gee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tACK e1b0798 on WSL Ubuntu 22.04 on signet no issues detected

Copy link
Contributor

@johnny9 johnny9 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK e1b0798

Before changes:

qrc:/qml/controls/Theme.qml:13:5: QML Settings: Failed to initialize QSettings instance. Status code is: 1
qrc:/qml/controls/Theme.qml:13:5: QML Settings: The following application identifiers have not been set: QVector("organizationName", "organizationDomain")

After:
No qml errors seen

@pablomartin4btc
Copy link
Contributor Author

Thanks @MarnixCroes, @D33r-Gee and @johnny9 for testing the bugfix!

@hebasto hebasto merged commit 58f8d44 into bitcoin-core:main Jan 14, 2024
2 checks passed
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.

QML source code error displayed on terminal if run app with invalid args
5 participants