Skip to content

refactor/ros-no-ros#14

Merged
YuanYuYuan merged 20 commits intomainfrom
refactor/ros-no-ros
Nov 17, 2025
Merged

refactor/ros-no-ros#14
YuanYuYuan merged 20 commits intomainfrom
refactor/ros-no-ros

Conversation

@YuanYuYuan
Copy link
Collaborator

@YuanYuYuan YuanYuYuan commented Nov 17, 2025

Summary of Changes

Architecture Refactoring

  • ROS-independent core: ros-z and ros-z-codegen now build without ROS dependencies
  • Modular workspace: Reorganized default members to only include ROS-independent packages
  • Feature-gated ROS support: RCL bindings (rcl-z) and external messages require explicit opt-in

Message System Enhancement

  • Dual message support in ros-z-msgs:
  • Bundled messages: Uses roslibrust assets for common_interfaces (std_msgs, geometry_msgs, sensor_msgs, nav_msgs) - no ROS required
  • External messages: Optional support for ROS-installed packages (example_interfaces) via external_msgs feature
  • Smart fallback mechanism: Automatically detects ROS installation or falls back to bundled definitions

Multi-Distro Support

  • Flexible Nix flake: Supports multiple ROS distros (Jazzy, Rolling) with separate dev shells
  • Distro-specific environments: nix develop .#{jazzy,rolling,noRos} for different use cases

CI/CD Improvements

  • Split CI workflow: Separate jobs for ROS-independent and ROS-dependent tests
  • Matrix testing: Tests across multiple ROS distributions (unstable rolling is disabled)
  • Quality gates: Added markdownlint and nix formatting checks
  • Interop tests: ROS interoperability verification between rmw_zenoh within a Ubuntu server

Documentation & Examples

  • Categorized examples:
    • Custom Rust messages (no deps)
    • Bundled messages (no ROS)
    • External messages (requires ROS)
    • Advanced protobuf demo

- Add default-members excluding ROS-dependent packages
- Move protobuf_demo to workspace members
- Update roslibrust dependency to latest commit
- Add factory functions to create environments for different ROS distros
- Support Jazzy and Rolling distributions
- Add noRos development shell without ROS dependencies
- Create per-distro CI shells (jazzy-ci, rolling-ci, noRos-ci)
- Generate packages for all supported distros
- Update dependencies (nix-ros-overlay, nixpkgs, rust-overlay)
- Add no-ros job testing core functionality without ROS
- Add with-ros job matrix for testing with different ROS distros
- Test bundled message features without ROS installation
- Test external message features with ROS installation
- Add protobuf feature testing
- Fix typo: requries -> requires
- Remove roslibrust from default features
- Make protobuf support opt-in
- Conditionally compile protobuf adapter
- Remove default RCL dependency lookups
- Split features into bundled (no ROS) and external (needs ROS)
- Add individual package features for fine-grained control
- Implement fallback search for ROS packages (system -> roslibrust)
- Make common_interfaces default (bundled messages only)
- Add all_msgs feature for bundled + external messages
- Print detailed cargo warnings about message sources
Add note explaining that rcl-z requires ROS Client Library dependencies
and how to exclude it from builds without ROS.
- Add protobuf and rcl-z as optional features
- Update z_pubsub example to use bundled messages
- Add z_custom_message example with Rust-defined messages
- Remove default ros-z-msgs dependency from core library
Add ros-msgs feature to gate ros-z-msgs dependency and allow testing
core functionality without ROS messages.
Move protobuf_demo to workspace member and update to demonstrate
both ROS message protobuf serialization and custom protobuf messages.
- Document default build without ROS dependencies
- Add bundled vs external message feature documentation
- Document workspace structure and member exclusions
- Add examples categorized by dependencies
- Document Nix shell options for different distros
- Add feature flags documentation for all packages
- Clarify build system search order for message packages
- Add markdownlint-cli to common build inputs
- Add Markdown formatting check to CI workflow
- Check all markdown files while ignoring target and node_modules
- Fix line length issues in README.md and _PROTOBUF.md
- Add blank lines around headings and lists
- Add code block language specifications
- Create .markdownlintignore for build artifacts and temp files
- Create .markdownlint.json to allow HTML in styled sections
- Update CI to use markdownlint config files
- Add "Check Nix formatting" step to CI workflow
- Run nixfmt-rfc-style on flake.nix
- Fix formatting issues in flake.nix
- Add external_msgs feature to ros-z that propagates to ros-z-msgs
- Require external_msgs feature for z_srvcli example
- Update README to document the feature and build command
- Fixes cargo test failure when building without ROS dependencies
- Add ros-z-msgs/external_msgs to interop-tests feature
- Update test.yml workflow to run interop tests correctly
- Change test command to: cargo test -p ros-z-tests --features interop-tests
- Rename workflow from "CI" to "Interop Tests" for clarity
- Clean up workflow formatting
@YuanYuYuan YuanYuYuan changed the title Refactor/ros no ros refactor/ros-no-ros Nov 17, 2025
@YuanYuYuan YuanYuYuan merged commit fa3179a into main Nov 17, 2025
3 checks passed
@YuanYuYuan YuanYuYuan deleted the refactor/ros-no-ros branch November 20, 2025 04:50
YuanYuYuan added a commit that referenced this pull request Dec 9, 2025
* refactor: restructure workspace for ROS-independent build

- Add default-members excluding ROS-dependent packages
- Move protobuf_demo to workspace members
- Update roslibrust dependency to latest commit

* refactor: support multiple ROS distros in Nix flake

- Add factory functions to create environments for different ROS distros
- Support Jazzy and Rolling distributions
- Add noRos development shell without ROS dependencies
- Create per-distro CI shells (jazzy-ci, rolling-ci, noRos-ci)
- Generate packages for all supported distros
- Update dependencies (nix-ros-overlay, nixpkgs, rust-overlay)

* ci: split workflow into ROS-independent and ROS-dependent jobs

- Add no-ros job testing core functionality without ROS
- Add with-ros job matrix for testing with different ROS distros
- Test bundled message features without ROS installation
- Test external message features with ROS installation
- Add protobuf feature testing
- Fix typo: requries -> requires

* refactor: make ros-z-codegen ROS-independent

- Remove roslibrust from default features
- Make protobuf support opt-in
- Conditionally compile protobuf adapter
- Remove default RCL dependency lookups

* feat: support bundled and external messages in ros-z-msgs

- Split features into bundled (no ROS) and external (needs ROS)
- Add individual package features for fine-grained control
- Implement fallback search for ROS packages (system -> roslibrust)
- Make common_interfaces default (bundled messages only)
- Add all_msgs feature for bundled + external messages
- Print detailed cargo warnings about message sources

* docs: add RCL dependency note to rcl-z

Add note explaining that rcl-z requires ROS Client Library dependencies
and how to exclude it from builds without ROS.

* refactor: make ros-z core ROS-independent

- Add protobuf and rcl-z as optional features
- Update z_pubsub example to use bundled messages
- Add z_custom_message example with Rust-defined messages
- Remove default ros-z-msgs dependency from core library

* refactor: make ros-z-tests dependencies optional

Add ros-msgs feature to gate ros-z-msgs dependency and allow testing
core functionality without ROS messages.

* feat: add protobuf demo as advanced example

Move protobuf_demo to workspace member and update to demonstrate
both ROS message protobuf serialization and custom protobuf messages.

* docs: comprehensive update for ROS-independent build

- Document default build without ROS dependencies
- Add bundled vs external message feature documentation
- Document workspace structure and member exclusions
- Add examples categorized by dependencies
- Document Nix shell options for different distros
- Add feature flags documentation for all packages
- Clarify build system search order for message packages

* feat: add markdownlint to development and CI

- Add markdownlint-cli to common build inputs
- Add Markdown formatting check to CI workflow
- Check all markdown files while ignoring target and node_modules

* fix: resolve markdownlint errors

- Fix line length issues in README.md and _PROTOBUF.md
- Add blank lines around headings and lists
- Add code block language specifications
- Create .markdownlintignore for build artifacts and temp files
- Create .markdownlint.json to allow HTML in styled sections
- Update CI to use markdownlint config files

* feat: add nix fmt check to CI and fix formatting

- Add "Check Nix formatting" step to CI workflow
- Run nixfmt-rfc-style on flake.nix
- Fix formatting issues in flake.nix

* chore: tidy .markdownlintignore

* fix: gate z_srvcli example behind external_msgs feature

- Add external_msgs feature to ros-z that propagates to ros-z-msgs
- Require external_msgs feature for z_srvcli example
- Update README to document the feature and build command
- Fixes cargo test failure when building without ROS dependencies

* fix: enable external_msgs for interop tests

- Add ros-z-msgs/external_msgs to interop-tests feature
- Update test.yml workflow to run interop tests correctly
- Change test command to: cargo test -p ros-z-tests --features interop-tests
- Rename workflow from "CI" to "Interop Tests" for clarity
- Clean up workflow formatting

* style: cargo fmt

* fix: correct z_srvcli example feature flag syntax

* perf: use release build for interop tests in CI

* ci: disable the interop test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant