-
Notifications
You must be signed in to change notification settings - Fork 98
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
Test included model folders missing model.config #422
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Currently there is a confusing error message if a file is loaded that finds a folder matching the name of a model to be included but the folder does not have a model.config file. This improves the first error message and stops further loading to prevent additional confusing messages. Signed-off-by: Steve Peters <scpeters@openrobotics.org>
Codecov Report
@@ Coverage Diff @@
## sdf9 #422 +/- ##
=======================================
Coverage 86.25% 86.26%
=======================================
Files 59 59
Lines 9181 9187 +6
=======================================
+ Hits 7919 7925 +6
Misses 1262 1262
Continue to review full report at Codecov.
|
chapulina
reviewed
Nov 21, 2020
Signed-off-by: Steve Peters <scpeters@openrobotics.org>
Signed-off-by: Steve Peters <scpeters@openrobotics.org>
chapulina
approved these changes
Nov 23, 2020
azeey
approved these changes
Nov 23, 2020
scpeters
added a commit
to scpeters/sdformat
that referenced
this pull request
Dec 14, 2020
Currently there is a confusing error message if a file is loaded that finds a folder matching the name of a model to be included but the folder does not have a model.config file. This improves the first error message and stops further loading to prevent additional confusing messages. Signed-off-by: Steve Peters <scpeters@openrobotics.org>
scpeters
added a commit
to scpeters/sdformat
that referenced
this pull request
Dec 15, 2020
Currently there is a confusing error message if a file is loaded that finds a folder matching the name of a model to be included but the folder does not have a model.config file. This improves the first error message and stops further loading to prevent additional confusing messages. Signed-off-by: Steve Peters <scpeters@openrobotics.org>
scpeters
added a commit
that referenced
this pull request
Dec 15, 2020
Currently there is a confusing error message if a file is loaded that finds a folder matching the name of a model to be included but the folder does not have a model.config file. This improves the first error message and stops further loading to prevent additional confusing messages. Signed-off-by: Steve Peters <scpeters@openrobotics.org>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Currently there is a confusing error message if a file is loaded that finds a folder matching the name of a model to
be included but the folder does not have a model.config file. This improves the first error message and stops further loading
to prevent additional confusing messages. To illustrate this, I've added a model folder
box_missing_config
totest/integration/model
containing amodel.sdf
but nomodel.config
and a test that tries to include a model matching that folder name. Without the change to parser.cc, the test prints the following:Note that
box_missing_config
is not listed anywhere, which makes it hard to figure out what is the cause of the problem. It also causesreadString
to fail. After modifying parser.cc, the parser doesn't fail and the test shows the following console output (the second message comes from printing out the errors returned byRoot::Load
):EDIT: it doesn't actually cause
sdf::readString
to fail, though it does return / print an error depending on which overload is called.