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

Better error messages when component can't be loaded #175

Merged
merged 1 commit into from
Feb 5, 2021

Conversation

chapulina
Copy link
Contributor

@chapulina chapulina commented Feb 5, 2021

Signed-off-by: Louise Poubel [email protected]

Related to #30

Summary

It's often difficult to find out why a QML file failed to load. With this PR we get more verbose error messages that should help users identify problems more easily.

For example, I was debugging some code where I was getting this message:

[GUI] [Err] [Plugin.cc:136] Failed to instantiate QML file [:/Scene3D/Scene3D.qml].
* Are you sure it's been added to the .qrc file?
* Are you sure the file is valid QML? You can check with the `qmlscene` tool

With this PR, I get this message:

[GUI] [Err] [Plugin.cc:146] Failed to instantiate QML file [:/Scene3D/Scene3D.qml].
* file::/Scene3D/Scene3D.qml:19:1: module "RenderWindow" is not installed

Checklist

  • Signed all commits for DCO
  • Added tests
  • Updated documentation (as needed)
  • Updated migration guide (as needed)
  • codecheck passed (See
    contributing)
  • All tests passed (See
    test coverage)
  • [ x While waiting for a review on your PR, please help review
    another open pull request
    to support the maintainers

Note to maintainers: Remember to use Squash-Merge

@chapulina chapulina added the enhancement New feature or request label Feb 5, 2021
@github-actions github-actions bot added the 🏰 citadel Ignition Citadel label Feb 5, 2021
@codecov
Copy link

codecov bot commented Feb 5, 2021

Codecov Report

Merging #175 (ea59762) into ign-gui3 (7863c80) will decrease coverage by 0.24%.
The diff coverage is 17.64%.

Impacted file tree graph

@@             Coverage Diff              @@
##           ign-gui3     #175      +/-   ##
============================================
- Coverage     59.12%   58.87%   -0.25%     
============================================
  Files            21       21              
  Lines          2608     2624      +16     
============================================
+ Hits           1542     1545       +3     
- Misses         1066     1079      +13     
Impacted Files Coverage Δ
src/Plugin.cc 57.44% <17.64%> (-2.83%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7863c80...0c894da. Read the comment docs.

Copy link
Contributor

@ahcorde ahcorde left a comment

Choose a reason for hiding this comment

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

+1 Really usefull to know where is the error in the QML

@chapulina chapulina merged commit 64c907c into ign-gui3 Feb 5, 2021
@chapulina chapulina deleted the chapulina/3/error_msgs branch February 5, 2021 16:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏰 citadel Ignition Citadel enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants