Skip to content

loxl: per-port descriptions in loxl types and the LSP - #304

Merged
discostu105 merged 1 commit into
mainfrom
loxl-port-descriptions
Nov 1, 2026
Merged

discostu105 merged 1 commit into
mainfrom
loxl-port-descriptions

Conversation

@discostu105

Copy link
Copy Markdown
Owner

Closes #301

Port keys are raw XML keys (Lr, Lbr, Au, AQh). Each builtin port now has a line from its block's Loxone knowledge-base page (reference kb-block-pages, one page per type in blockdoc::kb_page). The line shows in:

  • loxl types <Type>: under the port
  • loxl types --json: as description
  • the LSP: in the port hover and in the completion detail

No aliases.

  • src/port_doc.rs (hand-written): for each port, the key, its abbreviation on the page, and one line in our own words. Other ports are named by their keys.
  • A key maps to an abbreviation only with evidence. In order: the canvas label, the TechDoc label, a key that spells the abbreviation, or the Reset→Off mapping the simulator already uses. A port with none of these gets no line.
  • tools/check-port-docs.py downloads the pages into refs/kb/ and checks every abbreviation. A unit test checks the abbreviations against the known canvas labels.
  • Coverage: 554 of 696 ports, in 40 of 48 types. The gaps are listed in decision 0088.
  • kb_page now covers every type with descriptions. Equal, NotEqual, GreaterEqual and LessEqual now link their own pages instead of comparator, which documents a different block.
  • loxone-config is bumped to 0.14.1.

Compile output is unchanged: the compiler is not touched.

https://claude.ai/code/session_01Ms544bon1xvxMStUjX3BKG

Port keys are raw XML keys (Lr, Lbr, Au, AQh). src/port_doc.rs gives each
port a line written from its block's Loxone knowledge-base page, with the
page abbreviation it maps to. A key maps only by evidence: the canvas label,
the TechDoc label, a key that spells the abbreviation, or the mapping the
simulator already models. Undocumented ports get no line.

loxl types prints the line under each port and --json gives it as
`description`; the language server shows it in the port hover and the
completion detail. tools/check-port-docs.py checks every abbreviation
against the pages. 554 of 696 ports in 40 of 48 types.

Closes #301

Claude-Session: 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 99.76190% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 74.65%. Comparing base (e4dab50) to head (fe54f44).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
crates/loxone-config/src/lsp/analysis.rs 88.88% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #304      +/-   ##
==========================================
+ Coverage   74.20%   74.65%   +0.44%     
==========================================
  Files         134      135       +1     
  Lines       44331    44746     +415     
==========================================
+ Hits        32898    33403     +505     
+ Misses      11433    11343      -90     
Files with missing lines Coverage Δ
crates/loxone-config/src/blockdoc.rs 99.00% <100.00%> (+3.62%) ⬆️
crates/loxone-config/src/cli.rs 52.92% <100.00%> (+0.16%) ⬆️
crates/loxone-config/src/port_doc.rs 100.00% <100.00%> (ø)
crates/loxone-config/src/lsp/analysis.rs 89.18% <88.88%> (-0.06%) ⬇️

... 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 merged commit 83ea456 into main Nov 1, 2026
9 checks passed
@discostu105
discostu105 deleted the loxl-port-descriptions branch November 1, 2026 09:03
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: per-port descriptions in loxl types and LSP hover

1 participant