Skip to content

Upgrading the Cosmos -> XTCE converter to support v1.2.#2615

Merged
jmthomas merged 41 commits intoOpenC3:mainfrom
alex-pope-sdl:main
Dec 16, 2025
Merged

Upgrading the Cosmos -> XTCE converter to support v1.2.#2615
jmthomas merged 41 commits intoOpenC3:mainfrom
alex-pope-sdl:main

Conversation

@alex-pope-sdl
Copy link
Copy Markdown
Contributor

The current Cosmos -< XTCE converter only supports v1.1. These changes upgrade the converter to be XTCE v1.2 compliant and includes various improvements such as:

  • Handling of Multi-target Cosmos definitions by use of Sub-Spacesystems
  • Handling of non-XTCE compliant names by use of Aliases under "COSMOS" namespace
  • Handling of "ALLOW_SHORT" telemetry through use of AncillaryData
  • Handling of dynamic strings
  • Placeholders for derived tlm and PACKET_TIME override
  • Shrinking the generated XTCE down by removing redundant base containers
  • Converting CMD ID_PARAMETERS into XTCE Parameters
  • Combining Multiple xtce files into a single file by use of Sub-Spacesystems

Merge in PRWL/cosmos from feature/xtce_1.2_support to main

* commit '7010de6ed5f3377cd7d5151ee4b3fc38965ab036':
  PRWL-2290 added args that don't clash and the correct initial values, updated tests for it.
  PRWL-2290 removed xtce samples
  PRWL-2290 fixed a little endian thing
  PRWL-2290 redid some unit tests
  PRWL-2290 cleanup
  PRWL-2290 switched to only supporting xtce v1.2
  PRWL-2290 added handler for matching cmd and tlm id names
  PRWL-2290 unit tests for xtce conversion
  PRWL-2290 added unit tests for most of the features. Missing derived tlm still
  PRWL-2290 subsystems with extra root specification using -r
  PRWL-2247 added split subsystems on multi target. No extra root element yet
  PRWL-2247 Added aliases and a couple of other converter improvements
  PRWL-2223 previous xtce1.2 work
…KET_TIME items

Merge in PRWL/cosmos from feature/derived_item_templates_in_xtce_converter to main

* commit 'fcabcd53818242d599c22034ca7f6ab8ee16c9e2':
  PRWL-2298 made the time association an argument
  PRWL-2289 fixed unit test
  PRWL-2298 removed extra comments
  PRWL-2298 removed puts
  PRWL-2298 derived and packet time
@codecov
Copy link
Copy Markdown

codecov bot commented Dec 12, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 79.23%. Comparing base (4129e58) to head (18ff5ff).
⚠️ Report is 289 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2615      +/-   ##
==========================================
- Coverage   79.63%   79.23%   -0.40%     
==========================================
  Files         658      662       +4     
  Lines       50420    52407    +1987     
  Branches      736      734       -2     
==========================================
+ Hits        40154    41527    +1373     
- Misses      10186    10800     +614     
  Partials       80       80              
Flag Coverage Δ
python 81.22% <ø> (-0.43%) ⬇️
ruby-api 84.48% <ø> (-0.09%) ⬇️
ruby-backend 82.20% <ø> (-0.75%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@jmthomas
Copy link
Copy Markdown
Member

This is awesome! Thanks! I made a few changes but wasn't able to push to your PR. Maybe because this is all on main instead of a branch? Could you ensure I can change this PR by checking out this guide: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/allowing-changes-to-a-pull-request-branch-created-from-a-fork

@jmthomas
Copy link
Copy Markdown
Member

Alternatively can you apply this patch:

diff.patch

@jmthomas jmthomas self-requested a review December 12, 2025 19:55
Copy link
Copy Markdown
Member

@jmthomas jmthomas left a comment

Choose a reason for hiding this comment

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

What are the various TODOs throughout?

Please apply to patch to fix spelling and spec errors.

Merge in PRWL/cosmos from new-main to main

* commit '8430c291b0f8186eaf2b5bda64b2e7978f47b7d2': (155 commits)
  made the time association an argument
  fixed unit test
  removed extra comments
  removed puts
  derived and packet time
  added args that don't clash and the correct initial values, updated tests for it.
  removed xtce samples
  fixed a little endian thing
  redid some unit tests
  cleanup
  Switched to only supporting xtce v1.2
  added handler for matching cmd and tlm id names
  unit tests for xtce conversion
  Added unit tests for most of the features. Missing derived tlm still
  Subsystems with extra root specification using -r
  Added split subsystems on multi target. No extra root element yet
  Added aliases and a couple of other converter improvements
  Previous xtce1.2 work
  Fix playwright
  Make js-common relative in vue-common
  ...
@alex-pope-sdl
Copy link
Copy Markdown
Contributor Author

alex-pope-sdl commented Dec 16, 2025

Oops sorry about that. I believe you're right since I used main in my fork it blocked pushes to it. I'll be sure to use a feature branch next time. I applied the provided patch and removed some left over todos in the changes. The todos that go in the XTCE are left as templates to fill in. With the derived tlm it's impossible to know all of the required information from the Cosmos defs alone so the best I could do was leave them as TODO's with some information filled in.

@jmthomas jmthomas self-requested a review December 16, 2025 22:16
@jmthomas jmthomas merged commit ae28e90 into OpenC3:main Dec 16, 2025
25 of 28 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.

2 participants