Skip to content

Merge dev into master for XRobot 1.0 - #5

Merged
Jiu-xiao merged 14 commits into
masterfrom
dev
Oct 4, 2026
Merged

Jiu-xiao merged 14 commits into
masterfrom
dev

Conversation

@Jiu-xiao

@Jiu-xiao Jiu-xiao commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor

把 dev 合入 master。迁移到 XRobot 1.0 的模块约定(静态装配),具体改动见下方提交列表。

Merges dev into master. Migrates the Module to the XRobot 1.0 conventions (static assembly); the commits below list the changes.

合并顺序:libxr、CodeGenerator、扩展和 XRobot 先合并并发布(xrobot 1.0.0、libxr 6.0.0、扩展 2.0.0,XRobot 打 v1);模块的 PR 在 xrobot 1.0.0 发布之后再合并,因为模块 master 合入后,xrobot 0.3.x 拉到的就是 MODULE MANIFEST V2 的模块。

Merge order: libxr, CodeGenerator, the extension and XRobot are merged and released first (xrobot 1.0.0, libxr 6.0.0, extension 2.0.0, XRobot tag v1); the Module PRs follow after xrobot 1.0.0 is released, because once a Module's master carries MODULE MANIFEST V2, xrobot 0.3.x fetches that format.

验证 / Verification

  • dev 上的 Module CI 通过(2026-10-03,XRobot dev ac729b0d、LibXR dev 585b59f)。

提交 / Commits

  • feat: adopt static module construction (4dfad7e)
  • Migrate to static assembly (9eb6981)
  • Merge origin/master into feat/static-assembly-20260915 (62d4069)
  • Require optional dependency pointers to be passed explicitly (65527b4)
  • Remove the empty OnMonitor hook (c380f60)
  • Add the Apache-2.0 license (0f97e78)
  • Use the shared XRobot Module CI workflow (98d68a2)
  • Rewrite the README for XRobot 1.0 (ea4e901)
  • Take the subscribed topic names from Param (a6494fd)
  • Document the configurable topic names (011758d)

Summary by Sourcery

Migrate the InfantryLauncher module to the XRobot 1.0 static assembly conventions and shared module infrastructure.

New Features:

  • Adopt XRobot 1.0 static module assembly with explicit dependency injection and configurable topic names.
  • Expose comprehensive InfantryLauncher configuration and document its construction, topics, behavior, dependencies, and integration example.

Enhancements:

  • Refactor the launcher to use references for required dependencies and a consolidated parameter structure, while removing the obsolete monitor hook.
  • Update the module manifest to version 2 dependency declarations and add bilingual module metadata.
  • Add the Apache-2.0 license.

CI:

  • Replace the bespoke module build workflow with the shared XRobot Module CI workflow using configurable XRobot, LibXR, and dependency branches.

Documentation:

  • Rewrite the README for XRobot 1.0 with API, configuration, topic, behavior, and dependency documentation.

Merged master commits and verdicts:
- 0a5efcb fix: validate required launcher providers before setup
  superseded: CMD and the friction/trigger motors are references in the
  static-assembly constructor, Referee stays an optional pointer; Motor and
  Referee are already declared in the manifest.

Conflicts resolved in favour of the static-assembly branch.
Optional dependencies are pointer parameters without a default argument; configurations pass nullptr to omit them.
The static-assembly entry calls OnMonitor() only for modules that declare it; the empty body was left over from the removed application framework.
The XRobot ecosystem Modules are published under the Apache License 2.0; the text
is identical to xrobot-org/XRobot/LICENSE.
Replace the generated inline workflow with a caller of
xrobot-org/XRobot/.github/workflows/module-ci.yml, which resolves the
dependencies, compiles the Module sources and a generated constructor probe
against LibXR.

During the coordinated 1.0 change the tools, LibXR and same-or-dev dependencies
come from dev.
Describe the Module, its dependencies, its constructor (dependencies first, then
the value configuration) and its use with xrobot module add / setup / instance
add, with a configuration example seeded by the tool. Drop the dynamic-framework
text and the dead MIGRATION.md link.
InfantryLauncher subscribed to "launcher_cmd" and "launcher_ref" by fixed names
while CMD and Referee publish them under configurable ones. Param gains
launcher_cmd_topic_name and launcher_ref_topic_name, defaulting to the
old names.
List the new topic name parameters with their defaults, show them in the
configuration example, and say which publisher setting each must match.

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @Jiu-xiao, you've used your own review budget of 250,000 diff characters for the last 7 days.

You can request another review in 7 days by commenting @sourcery-ai review. Upgrade to get a review now.

@sourcery-ai

sourcery-ai Bot commented Oct 3, 2026

Copy link
Copy Markdown

Reviewer's Guide

This PR migrates InfantryLauncher to XRobot 1.0 static assembly by changing manifest and constructor dependency handling, exposing topic names and runtime configuration through Param, adopting shared dev-based Module CI, and updating documentation and licensing.

Sequence diagram for static module initialization and topic subscription

sequenceDiagram
    participant XRobot
    participant Generator as CodeGenerator
    participant InfantryLauncher
    participant CMD
    participant RMMotor
    participant Topic

    XRobot->>Generator: xrobot setup
    Generator->>InfantryLauncher: construct with explicit dependencies and Param
    InfantryLauncher->>RMMotor: store motor references
    InfantryLauncher->>CMD: GetEvent().Register(...)
    InfantryLauncher->>InfantryLauncher: Thread::Create(ThreadFunc)
    InfantryLauncher->>Topic: ASyncSubscriber(launcher_cmd_topic_name_)
    InfantryLauncher->>Topic: ASyncSubscriber(launcher_ref_topic_name_)
    Topic-->>InfantryLauncher: command and referee data
Loading

File-Level Changes

Change Details Files
Migrate module construction and manifest metadata to XRobot 1.0 static assembly.
  • Replace constructor-argument manifest entries with explicit dependency IDs and refs.
  • Change the constructor to accept required module instances by reference and consolidate configurable values in Param.
  • Remove application-manager/hardware-container integration and the empty monitor hook.
  • Preserve optional Referee support while requiring core dependencies explicitly.
InfantryLauncher.hpp
Make topic names configurable through static-assembly parameters.
  • Add command and referee topic-name fields to Param with defaults.
  • Initialize subscribers from configured topic names instead of hard-coded strings.
  • Document topic configuration and dependency-instance wiring.
InfantryLauncher.hpp
README.md
Adopt the shared XRobot module CI workflow.
  • Replace the bespoke container, dependency checkout, module setup, build, and tag workflow with the reusable Module CI workflow.
  • Configure CI to test XRobot, libxr, and dependencies from their dev references.
.github/workflows/build.yml
Document the XRobot 1.0 module interface and usage.
  • Rewrite the README with behavior, configuration, constructor, dependency, topic, and setup documentation.
  • Add the Apache-2.0 license.
README.md
LICENSE

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@Jiu-xiao
Jiu-xiao merged commit de76bb4 into master Oct 4, 2026
4 checks passed
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