Skip to content

loxl: unit suffixes on extern sets, template parameters and HTTP input settings - #330

Merged
discostu105 merged 1 commit into
mainfrom
i299-unit-suffix
Nov 1, 2026
Merged

discostu105 merged 1 commit into
mainfrom
i299-unit-suffix

Conversation

@discostu105

Copy link
Copy Markdown
Owner

Closes #299

  • The unit-suffix lint and lint --fix now also cover port assignments on externs (x.TimeEnd = 120 → 2min; a bulk line (a, b).Port = … changes only as a whole), template value-parameter defaults and the instances' arguments for them (only when every use of the parameter in the body is a port of the same unit and nothing else names it), and arguments forwarded to the primary block. --fix uses the whole directory module, so templates and externs in other files count.
  • Milliseconds are a port unit now (4s → 4000).
  • Units of device settings come from Loxone's knowledge base, in a new hand-written table src/settings_meta.rs (documented in loxone-format.md, references added to docs/references.json): VirtualHttpIn Poll in s (10…604800), Timeout in ms (10…8000), Allowedtimeouts 0…100. Adopt writes them with a suffix.
  • No Loxone page gives a unit for the Modbus server's Timeout or the Modbus sensors' ModbusPollingCycle/MinTime/MaxTime (or VirtualUdpInCmd MinTime). They stay bare numbers.
  • Decision D111. loxone-config 0.16.0 (new PortUnit variant).

The compile output does not change. The house config: lint --fix rewrites 36 values in 8 files, and out.Loxone and the lock stay byte-identical.

https://claude.ai/code/session_01Ms544bon1xvxMStUjX3BKG

@discostu105 discostu105 added the release:minor Auto-release: bump the minor version label Nov 1, 2026
@codecov

codecov Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 96.38554% with 6 lines in your changes missing coverage. Please review.
✅ Project coverage is 74.97%. Comparing base (63aed80) to head (7c40078).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
crates/loxone-config/src/lsp/analysis.rs 25.00% 3 Missing ⚠️
crates/loxone-config/src/logic/lint.rs 98.55% 2 Missing ⚠️
crates/loxone-config/src/connectors.rs 50.00% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #330      +/-   ##
==========================================
+ Coverage   74.90%   74.97%   +0.06%     
==========================================
  Files         139      140       +1     
  Lines       45510    45656     +146     
==========================================
+ Hits        34089    34230     +141     
- Misses      11421    11426       +5     
Files with missing lines Coverage Δ
crates/loxone-config/src/cli.rs 53.28% <100.00%> (+0.19%) ⬆️
crates/loxone-config/src/logic/adopt_tree.rs 68.16% <100.00%> (+0.11%) ⬆️
crates/loxone-config/src/logic/ast.rs 95.11% <100.00%> (+0.12%) ⬆️
crates/loxone-config/src/port_meta.rs 100.00% <100.00%> (ø)
crates/loxone-config/src/settings_meta.rs 100.00% <100.00%> (ø)
crates/loxone-config/src/connectors.rs 87.41% <50.00%> (-0.25%) ⬇️
crates/loxone-config/src/logic/lint.rs 89.78% <98.55%> (+1.56%) ⬆️
crates/loxone-config/src/lsp/analysis.rs 88.92% <25.00%> (-0.30%) ⬇️

... and 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@discostu105
discostu105 force-pushed the i299-unit-suffix branch 2 times, most recently from 9e68cc0 to 3ac1be5 Compare November 1, 2026 09:59
…t settings (#299)

- `unit-suffix` lint and `lint --fix` cover extern port assignments
  (bulk lines change as a whole), template value-parameter defaults,
  instance arguments and forwarded instance bindings; --fix sees the
  whole directory module.
- Milliseconds become a port unit. VirtualHttpIn `Poll` (s) and
  `Timeout` (ms) units and ranges from Loxone's knowledge base, in a
  hand-written settings_meta table; adopt writes them with a suffix.
- Modbus settings have no documented unit and stay bare numbers.
- Decision D111; loxone-config 0.16.0.

Closes #299

Claude-Session: https://claude.ai/code/session_01Ms544bon1xvxMStUjX3BKG
@discostu105
discostu105 merged commit 020b470 into main Nov 1, 2026
9 checks passed
@discostu105
discostu105 deleted the i299-unit-suffix branch November 1, 2026 10:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release:minor Auto-release: bump the minor version

Projects

None yet

Development

Successfully merging this pull request may close these issues.

loxl: unit-suffix coverage — extern sets, template defaults, undocumented periphery units

1 participant