Closed hsd-dev closed 4 years ago
Ha, CI is actually working:
/scripts/yamale.bug:33:13: [error] no new line character at the end of file (new-line-at-end-of-file)
;)
YAML
schema seems to be complete. Will run the validator on the bugs and will get the most commonly occurring values.
Ping @ipa-hsd: could you update us on the status of this PR?
Command:
find ../ -name "*.bug" | xargs -I {} ./validate.sh {}
Example out of the script (it checks for all bug files at once):
Error validating data '../universal_robot/fc95a19/fc95a19.bug' with './robust.yaml'
bug.package: 'ros-industrial/universal_robot/ur_driver' is not a list.
bug.languages: 'None' is not a list.
bug.time-reported: '2014-10-10 (02:34)' is not a date.
bug.time-reported: '2014-10-10 (02:34)' is not a null.
bug.trace: 'None' is not a str.
fix.repo: 'https://github.com/ros-industrial/universal_robot/' is not a regex match.
fix.languages.0: 'Python' not in ('python', 'cmake', 'C++', 'package.xml', 'launch.xml', 'msg', 'srv', 'xacro', 'urdf', 'robot specific')
fix.time: '2014-11-03 (16:30)' is not a date.
fix.time: '2014-11-03 (16:30)' is not a null.
time-machine: Required field missing
bugzoo: Required field missing
@wasowski the new commits added addresses https://github.com/robust-rosin/robust/issues/370
The taxonomy notes the time is in the format 2017-12-31 (23:59)
. Changed the time to Z-notation UTC timestamp
in https://github.com/robust-rosin/robust/pull/359/commits/56c54eb86fd9c1ab53497c2127b3dddc1aa99478. With the earlier format the validation fails.
For my ref:
awk '/time:/ && /\)$/ {gsub(/\(|\)/,"");str=$2" "$3; gsub(str, $2"T"$3":00Z")}1' "$file"
The timestamps should actually be in ISO 8601 format.
I believe what you have (now) is in that format, but just wanted to mention the "official" name.
Note btw: I'm not sure you can just use the awk
command you have to rewrite all timestamp to UTC time like that. If the author of the bug description file is in another timezone, you'll have to convert the timestamps to UTC (ie: subtract delta-t from UTC, etc).
Just changing the format is not going to result in correct timestamps.
Having incorrect timestamps will lead to the time-machine using incorrect rosdistro
state, etc.
It's probably worth adding a particular version of yamale
to scripts/requirements.txt
. E.g., yamale==3.0.4
.
@gavanderhoorn @ChrisTimperley please take a look now.
addressed the inline comments by @gavanderhoorn. Merging this PR.
Bit of a pet peeve, sorry, but remember to squash and rebase next time so that we maintain a sensible commit history on master
👍🏻
Fixes most of the issues with the schema.
Though this doesn't allow automating fixing the bug files in any way. Porting to yamale. See https://github.com/robust-rosin/robust/issues/355