duckietown_utils is now in duckietown-utils-daffy. The lib is called duckietown_code_utils to avoid clashes. Also grouped together functions in duckietown_rosdata_utils (needs ROS) and duckietown_rosbag_utils (for bags).
fixed all python 2 to python 3 issues - there were many!
Python & YAML code reformatting using Black
fixed many code idioms (e.g. using f-strings rather than %)
added typing information to many functions
changed some NamedTuples to dataclasses (still many to go)
caught a few bugs
reintegrated all the packages needed to do unit tests. Note: there are some that after all are not needed. To be removed in second phase. However, also note we like to have old stuff (if it doesn't conflict) to try alternatives using regression tests.
re-added the config files needed for interpreting the logs in complete_image_pipeline.
added unit test job to circle.yml (parallel to docs job)
regression tests now pass
promote use of logger rather than print()
added missing dependencies (apt and pip)
removed OrderedDict - no need anymore
readapted some code from tests to changes in API
cleaned up the setup.py in ROS packages that referred to non-existing packages
promote correct use of exceptions and re-raising (people would not re-raise - always re-raise and fail)
added fake subtypes (NewTypes) that revealed a few errors regarding image conversions and such.
removed logging from matplotlib.font_manager
fixed typos in strings (e.g. "Initialzing")
using *=, /= where appropriate instead of a = a * ... - saves memory.
removed all imports inside functions (with few exceptions) - makes a speed difference when the package does reinitialization every time (when modules patch import)
always using os.path.join for creating paths
added __all__ to avoid too many symbols exported (work in progress)
Type of change
Please mark the relevant options with X:
[x] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] This change is constrained only to one package, any interfaces to nodes from other packages are maintained
[x] This change is constrained only to packages in this repository, any interfaces to nodes from other repositories are maintained
[ ] This change required a documentation update
[ ] This change is only a documentation update
[x] This change restructures the repository (at level higher than package level)
[ ] This change requires a change in the Duckiebook (if yes, please describe and, if possible, make a pull request for an edit in the book and link it here)
Tests
Please describe all tests ran and their outcome. It is highly recommended that you at least do the tests listed by default, even if you only changed the documentation.
[ ] Made the Duckiebot move with keyboard control
[ ] Visually checked the published camera stream
[ ] Verified that the lane following demo works
[ ] Verified that the indefinite navigation demo works
Style compliance
Please make sure that all your changes conform to the Duckietown (code style)[link] and code (documentation style)[link] guidelines:
[x] I have performed a self-review of my own code
[x] I have commented my code, particularly in hard-to-understand areas
[x] I checked that this pull request is compliant with the Duckietown code style
[x] I checked that this pull request is compliant with the Duckietown code documentation style
Next steps
Please describe if you have any questions, comments, or doubts towards the Duckietown software guardians regarding implementation, code style, running tests, documentation, etc.
FOR THE REVIEWERS
IMPORTANT: DO NOT CHANGE THIS SECTION!
[ ] Functionality (is the change necessary and is it implemented in the most appropriate way): @liampaull or @afdaniele
[ ] Integration testing (verify the tests and run additional if necessary): @?
[ ] Code style compliance: @gibernas
[ ] Documentation compliance: @aleksandarpetrov
To the reviewers: If you deem necessary, request code edits, more tests, documentation update, or additional reviewing. Do not review your own code!
Description
Main changes:
duckietown_code_utils
to avoid clashes. Also grouped together functions induckietown_rosdata_utils
(needs ROS) andduckietown_rosbag_utils
(for bags).complete_image_pipeline
.print()
matplotlib.font_manager
*=
,/=
where appropriate instead ofa = a * ...
- saves memory.os.path.join
for creating paths__all__
to avoid too many symbols exported (work in progress)Type of change
Please mark the relevant options with X:
Tests
Please describe all tests ran and their outcome. It is highly recommended that you at least do the tests listed by default, even if you only changed the documentation.
Style compliance
Please make sure that all your changes conform to the Duckietown (code style)[link] and code (documentation style)[link] guidelines:
Next steps
Please describe if you have any questions, comments, or doubts towards the Duckietown software guardians regarding implementation, code style, running tests, documentation, etc.
FOR THE REVIEWERS
IMPORTANT: DO NOT CHANGE THIS SECTION!
To the reviewers: If you deem necessary, request code edits, more tests, documentation update, or additional reviewing. Do not review your own code!
PR Template, last edit 23 Aug 2019