Repository navigation
refactor(architecture): add typed controller command and snapshot contracts - #214
Conversation
✅
|
| Descriptor | Linter | Files | Fixed | Errors | Max errors | Warnings | Elapsed time |
|---|---|---|---|---|---|---|---|
| ✅ ACTION | actionlint | 8 | 0 | 0 | 0.63s | ||
| ✅ BASH | bash-exec | 2 | 0 | 0 | 0.51s | ||
| ✅ BASH | shellcheck | 2 | 0 | 0 | 0.54s | ||
| ✅ BASH | shfmt | 2 | 0 | 0 | 0.01s | ||
| ✅ C | clang-format | 1 | 0 | 0 | 0.04s | ||
| ✅ C | cppcheck | 1 | 0 | 0 | 0.02s | ||
| ✅ C | cpplint | 1 | 0 | 0 | 0.28s | ||
| ✅ CPP | clang-format | 90 | 0 | 0 | 0.62s | ||
| ✅ CPP | cppcheck | 90 | 0 | 0 | 5.56s | ||
| ✅ CPP | cpplint | 90 | 0 | 0 | 6.81s | ||
| ✅ EDITORCONFIG | editorconfig-checker | 275 | 0 | 0 | 0.6s | ||
| ✅ JSON | jsonlint | 6 | 0 | 0 | 0.12s | ||
| ✅ JSON | v8r | 6 | 0 | 0 | 4.33s | ||
| markdownlint | 107 | 4 | 0 | 4.1s | |||
| ✅ YAML | yamllint | 26 | 0 | 0 | 1.11s |
Detailed Issues
⚠️ MARKDOWN / markdownlint - 4 errors
.opencode/skills/web-ui/SKILL.md:34 error MD028/no-blanks-blockquote Blank line inside blockquote
docs/superpowers/plans/2026-08-10-olimex-c6-local-ui-implementation.md:106:401 error MD013/line-length Line length [Expected: 400; Actual: 452]
docs/superpowers/plans/2026-08-16-norvi-button-calibration.md:7:401 error MD013/line-length Line length [Expected: 400; Actual: 412]
openspec/changes/controller-architecture-contracts/design.md:171:401 error MD013/line-length Line length [Expected: 400; Actual: 448]
Notices
MAKEFILE, MAKEFILE_CHECKMAKE, MARKDOWN_MARKDOWN_LINK_CHECK. See Removed linters to find their replacements.
See detailed reports in MegaLinter artifacts
Your project could benefit from a custom flavor, which would allow you to run only the linters you need, and thus improve runtime performances. (Skip this info by defining FLAVOR_SUGGESTIONS: false)
- Documentation: Custom Flavors
- Command:
npx mega-linter-runner@10.1.0 --custom-flavor-setup --custom-flavor-linters ACTION_ACTIONLINT,BASH_EXEC,BASH_SHELLCHECK,BASH_SHFMT,C_CPPCHECK,C_CPPLINT,C_CLANG_FORMAT,CPP_CPPCHECK,CPP_CPPLINT,CPP_CLANG_FORMAT,EDITORCONFIG_EDITORCONFIG_CHECKER,JSON_JSONLINT,JSON_V8R,MARKDOWN_MARKDOWNLINT,YAML_YAMLLINT

Show us your support by starring ⭐ the repository
Native Test Coverage
Report from native unit tests (ASan + gcov). |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d81eeaa3ec
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Native Test Coverage
Report from native unit tests (ASan + gcov). |
1 similar comment
Native Test Coverage
Report from native unit tests (ASan + gcov). |
Native Test Coverage
Report from native unit tests (ASan + gcov). |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Native Test Coverage
Report from native unit tests (ASan + gcov). |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Native Test Coverage
Report from native unit tests (ASan + gcov). |
1 similar comment
Native Test Coverage
Report from native unit tests (ASan + gcov). |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
1 similar comment
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Native Test Coverage
Report from native unit tests (ASan + gcov). |
1 similar comment
Native Test Coverage
Report from native unit tests (ASan + gcov). |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 52b88a8c94
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Co-authored-by: stritti <stritti@users.noreply.github.com>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Co-authored-by: stritti <stritti@users.noreply.github.com>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Native Test Coverage
Report from native unit tests (ASan + gcov). |
Co-authored-by: stritti <stritti@users.noreply.github.com>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Native Test Coverage
Report from native unit tests (ASan + gcov). |
Co-authored-by: stritti <stritti@users.noreply.github.com>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Native Test Coverage
Report from native unit tests (ASan + gcov). |
Summary
Introduces the fixed-size, allocation-free controller command and immutable snapshot contracts needed for the architecture migration discussed in #170, without changing production behavior yet.
Contract surface
OperationModewith stableauto/manu/boost/timerwire valuesControllerCommandcovering existing runtime controller mutationsSET_NTP_SERVERplusControllerSettingsSnapshot::ntpServerusing a shared 127-byte-plus-NUL value with rejection instead of truncationCYCLE_MODE, evaluated by the owner against current state rather than an adapter snapshotSensorSnapshotwith generation/timestamp, mapping identity and a deduplicated 20-device detected inventory with independent reading validitySystemSnapshotprojections for timer runtime, temperature-circulation settings, runtime settings and GREEN/YELLOW/RED time degradation4 x uint8_t + valid) inNetworkSnapshotSystemSnapshotScope boundary
The general controller command queue owns runtime controller/domain settings that must obey the Core-1 single-writer rule. WiFi/MQTT credentials and authentication secrets remain in dedicated provisioning/auth services.
NTP server text is a runtime controller setting, so validation/persistence belongs to Core 1. NTP client/network lifecycle remains owned by the time service. Local IP and heap values are read-only snapshot projections; outbound adapters format/use those copies rather than querying
NetworkManager,WiFiorESPafter adoption.Architectural constraints
manuControllerCommand156 bytes,SensorSnapshot376 bytes,SystemSnapshot596 bytes; transport PRs must verify queue/store and critical-section budgetsFollow-up dependency graph
Minimal robust graph:
#214 -> {#216, #217}{#216, #217, #170 sensor ownership} -> #218for the sensor-dependent adapter migration#218 -> #219{#214, #170} -> #220, independently of refactor(domain): make control rules return decisions instead of driving relays #219{#218, #219, #220} -> #221#216 and #217 are currently stacked on an older #214 contract and must be synchronized with this completed surface. #218 already contains the current #216 and #217 heads as ancestors, so it should be restacked after those foundation PRs rather than reintroducing queue/store implementations.
For #218 sensor reads, first project the sensor owner's cached acquisition/discovery generation. If that bridge is not used, #220 becomes a hard predecessor of the sensor-read part of #218. #170 remains the ownership gate before any cross-task Dallas adoption.
A conservative serial merge order is therefore
#214, #216, #217, #218, #219, #220, #221, with #216/#217 swappable and #220 movable earlier once #170 + #214 are satisfied.Detailed merge gates, NTP legacy-value handling, resource budgets and regression scenarios are in
openspec/changes/controller-architecture-contracts/design.mdand the contract specification.Validation
Current head:
f5994e78c2bb25020bfa5e7e40114bf2cec40471.esp32dev,norvi_ae01_randolimex_esp32_c6_evbSystemSnapshotretains a compile-time 600-byte budget guard and is 596 bytes on the native GCC ABIRelated to #170.