mirror of
https://github.com/craigerl/aprsd.git
synced 2026-10-09 16:50:31 -04:00
Replace the flat GPS fields on GPSPacket and its subclasses with a
composed Position value object (has-a instead of is-a), collapsing the
Packet -> GPSPacket -> {Beacon, MicE, Telemetry, Object, Weather}
data spine. Position owns the coordinates, symbol, movement/PHG data
and the conversion/formatting logic (zulu time, DDM, human_info).
- GPSPacket holds position: Optional[Position]; subclass defaults
preserved via _position_default() (ObjectPacket 'r', WeatherPacket '_')
- to_dict()/from_dict() flatten/unflatten so the on-disk JSON format
is unchanged; verified via objectstore save/load round-trip
- GPSPacket inherits DataClassJsonMixin directly because the
@dataclass_json decorator overwrites to_dict()/from_dict() and would
clobber the flattening overrides
- constructor is breaking: position=Position(...) instead of
latitude=.../longitude=...; updated tx.py, log.py and all tests
Full test suite (775) passes; ruff format + lint clean.