Skip to content

Decode ADS status messages without optional UTC time - #270

Open
Solarboaters wants to merge 1 commit into
schwehr:mainfrom
Solarboaters:fix/ads-missing-time
Open

Solarboaters wants to merge 1 commit into
schwehr:mainfrom
Solarboaters:fix/ads-missing-time

Conversation

@Solarboaters

Copy link
Copy Markdown

An ADS sentence without its optional UTC time currently raises TypeError in TimeUtc, interrupting both direct decoding and TAG-queue processing. Preserve the status fields and represent the absent time as when=None; do not invent a timestamp or substitute the independent TAG timestamp.

Fixes #217 and #111. The regressions replay the recorded sentence directly and through TagQueue, retain the original line and TAG timestamp, and confirm that a following valid AIS message decodes. A midnight control ensures that a real zero-valued time remains a time.

Validation (Linux, Python 3.12, GCC 13): the two reported paths fail before the change; 93 Python tests pass afterward. The C++ build and all 30 CTest executables pass with AddressSanitizer enabled. No live AIS receiver was tested.

AI-assisted investigation and patch; reviewed against the existing optional-time grammar and recorded input.

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.

HandlsAds/TimeUTC doesn't handle missing fields

1 participant