Skip to content

trend: read trend log multiple and event log objects (go-bacnet v0.7.0) - #19

Merged
boeboe merged 2 commits into
mainfrom
capture-validation
Nov 8, 2026
Merged

boeboe merged 2 commits into
mainfrom
capture-validation

Conversation

@boeboe

@boeboe boeboe commented Nov 8, 2026

Copy link
Copy Markdown
Contributor

Summary

Built on go-bacnet v0.7.0. go-bacnet now decodes the Log_Buffer records of Trend Log Multiple and Event Log objects; it refused them before. The defect was found in recorded traffic of a PolarSoft device and an Automated Logic device (go-bacnet testdata/captures).

  • trend on a trend log multiple: each record holds one value per logged property (kind "values", JSON values). A property the device could not read shows its error code.
  • trend on an event log: each record holds the event notification (kind "event", JSON event: event_object, event_type, from_state, to_state, notification_class, priority, message).
  • server run is unchanged. It installs the reinitialize hook, so go-bacnet's new refusal of backup states without a hook does not apply.
  • Test device: bactest.Logs() adds a trend log multiple and an event log with the recorded record forms. TestTrend reads both as table, text and JSON, with one request and with --all.
  • Docs: help text, README, docs/json-output.md, RELEASE.md v0.6.0.

Test plan

  • make check (coverage 94.5 %)
  • SAST make sast REPO=bacnetctl REF=capture-validation: no new findings. The 3 earlier findings are a G101 recorded as a false positive, a G101 and a G304, the last two below the threshold.

🤖 Generated with Claude Code

… v0.7.0)

go-bacnet v0.7.0 decodes Log_Buffer records of Trend Log Multiple and
Event Log objects, which it refused before (recorded traffic of a
PolarSoft and an Automated Logic device). trend prints one value per
logged property (kind values) and the event notifications (kind event).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@codecov

codecov Bot commented Nov 8, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 94.11765% with 8 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
internal/bac/trend.go 88.52% 6 Missing and 1 partial ⚠️
internal/bactest/requests.go 94.44% 0 Missing and 1 partial ⚠️

📢 Thoughts on this report? Let us know!

The simulated device has no backup or restore procedure; it acknowledged
START_BACKUP..ABORT_RESTORE. It now answers services/service-request-denied,
as go-bacnet v0.7.0's server does and recorded devices without backup
support do, and records the request as refused.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@boeboe
boeboe merged commit 8d93720 into main Nov 8, 2026
23 checks passed
@boeboe
boeboe deleted the capture-validation branch November 8, 2026 13:18
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