Repository navigation
Draw deployments with goby interface, optionally as D2, and check launch files against them - #57
Merged
Merged
Conversation
…nch files against them The deployment files list what each platform runs (run:) instead of naming interface files, with the arguments and configuration of their launch files, so 'goby launch <deployment>.yml' can start an example. With export_goby_interfaces, each deployment is drawn with 'goby interface visualize' into share/interfaces/figures/<name>_interfaces.pdf, now including the UDPM and Zenoh examples. build_interface_figures_d2 also writes each as a D2 diagram, rendered to SVG when d2 is found. With enable_tests, every listed deployment is validated (not just those with a test harness), and goby3_example_launch_<name>_<platform> runs 'goby interface launch_check' on its hand-written launch files. All of this needs a goby with 'goby interface'; with an older one the figures and checks are skipped with a status message. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TCmHEtuYatVV6nSaJPTa6z
…h keys The deployment files' run: entries carry launch keys (args, config, hold, enabled) that 'goby interface' reads only from the version that added 'goby interface launch'. An earlier one rejected them, failing the build while drawing the figures; the configure step now tries one such entry and skips the figures and checks with a status message instead. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TCmHEtuYatVV6nSaJPTa6z
Deleting build/share/interfaces/figures left the drawing step nothing to write into until CMake was rerun. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TCmHEtuYatVV6nSaJPTa6z
tsaubergine
force-pushed
the
interface-d2-figures
branch
from
November 12, 2026 04:56
0f931e5 to
f5ebba7
Compare
This file contains hidden or 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
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.
Stacked on #56.
Summary
build_interface_figures_d2option (OFF by default). Withexport_goby_interfaces=ON, each deployment is also written asshare/interfaces/figures/<name>_interfaces.d2. When thed2program is found it's rendered to.svg; otherwise the.d2files are written and a status message says they weren't rendered.goby interface visualize: now draws the existing Graphviz PDFs, replacinggoby_clang_tool -viz. The PDF names are unchanged. The UDPM and Zenoh examples now get figures too; Zenoh only when it's built.run:deployments: the deployment files list what each platform runs, with the arguments and config files from the matching.launchfiles, instead of listinginterfaces:files.gobydandgoby_mavlink_gatewayare found by name in Goby's own interfaces, so the@GOBY_INTERFACES_DIR@configure step is gone.goby launch hold_deployment.yml -x -I build/share/interfacesstarts an example straight from its deployment file.enabled: falsebecause the README has you start it by hand.goby interface launch_checktests: agoby3_example_launch_<name>_<platform>test compares each hand-written.launchfile with its deployment'srun:list. The.launchfiles are unchanged.goby interface validate --strictnow runs on every listed deployment, not only those with test harnesses.test/README.mdis updated..gitignoreignores the.<deployment>.launchfiles thatgoby launchwrites.Dependencies
These need a goby that has
goby interface: visualize/validate from GobySoft/goby3#446 and GobySoft/goby3#448, D2 from GobySoft/goby3#451,launch_checkandgoby launch <deployment>.ymlfrom GobySoft/goby3#458. With an older goby,export_goby_interfaces=ONbuilds the interface files but skips the figures and checks, and prints a status message. CI doesn't setexport_goby_interfaces, so it's unaffected.Test plan
interface-*branches withexport_goby_interfaces=ON enable_tests=ON build_interface_figures_d2=ON. All 10 deployments are drawn as PDF and D2.d2isn't installed here, so SVG rendering wasn't exercised.ctest -R "goby3_example_(interfaces|launch)": 21/21 pass, covering 10 validations and 11 launch-file checks.launch_checkfails (exit 1) on a copy ofhold.launchwithgobydremoved and an extra line added. It reportsnot-launched gobydandlaunched-only goby_logger.goby interface explainandgoby launchcommands work as written.Generated by Claude Code