[Epic] Meshtastic incoming packet pathway: correctness review

Abierto
#436 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
5/5
Tiempo estimado
Más de una semana
Aptitud para principiantes
15/100
Tipo de issue
Documentación
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
python
Área
api, backend

Línea de trabajo

This is an epic, not a single fix. Start by reading Meshflow/packets/views.py (PacketIngestView), Meshflow/packets/serializers.py and the docs in docs/features/packet-ingestion/. Pick one unchecked review area, such as the portnum inventory, and produce its part of the gap analysis. Done means a child issue is linked here and the matching field docs are updated. Wait for the 2.8.x work in #437 to land before touching shared files.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

enhancement needs-refinement

Summary

Epic. Do a thorough end-to-end review of the Meshtastic incoming packet pathway (bot → POST /api/packets/{node_id}/ingest/ → serializers → MtRawPacket / PacketObservation → signals → downstream apps) to make sure every packet type and field we receive is handled deliberately — stored, normalised, or knowingly ignored — rather than silently dropped or mis-parsed.

The 2.8.x firmware work has been split out to #437. Each checkbox below is a candidate child ticket. Raise child issues as they are scoped and link them here.

Sequencing with #437

  • Shared, do now under #437: the portnum/field inventory, test fixtures, and the protobuf/library bump. This epic reuses them rather than redoing them.
  • Correctness bugs found during the 2.8 work are fixed there, in the code it is already touching.
  • The rest of this review runs after the 2.8 must-haves land. It overlaps the remaining 2.8 work only where the two touch different files.

Review areas

Starting points: Meshflow/packets/views.py (PacketIngestView), Meshflow/packets/serializers.py, Meshflow/packets/services/, Meshflow/packets/receivers.py / signals.py, and the docs in docs/features/packet-ingestion/ (meshtastic.md, PACKET_FIELDS.md, DEDUPLICATION.md, signals.md).

  • Portnum inventory: list every portnum the firmware can emit; for each one, record what the bot forwards, what the API does with it (serializer / model / signal), and what happens to anything unhandled (reject, store raw, or drop). Flag the gaps.
  • Telemetry variants: check every Telemetry oneof (device, environment, air quality, power, health, host, local stats, traffic management) and its fields against the current protobufs. Look for fields we drop or name wrongly.
  • Packet envelope fields: hop_start, hop_limit, relay_node, next_hop, via_mqtt, rx_snr, rx_rssi, rx_time, channel, pki_encrypted, public_key, priority, transport_mechanism and so on. Note which we persist per packet and which per observation.
  • Encrypted / undecodable packets: what happens to them today, and is that what we want?
  • Dedup: re-check the dedup key and window (find_existing_packet, DEDUPLICATION.md) against relays, MQTT-bridged copies and multiple observers.
  • Error handling: validation failures, partial payloads and unknown enums. Make sure a single bad field doesn't cost us the whole packet without leaving a log.
  • Bot side: check the meshflow-bot transform (sanitise, channel inference, raw stripping) for anything lost before it reaches the API. If changes are needed there, raise a linked issue in meshflow-bot.
  • Tests: add fixture packets in docs/packets/ for each portnum and variant, and make sure every serializer has coverage.
  • Docs: update meshtastic.md / PACKET_FIELDS.md so they match reality.

Deliverables

  1. A written gap analysis added to docs/features/packet-ingestion/.
  2. A child issue for each concrete fix.
  3. Updated fixtures, tests and field docs.

Child tickets

None yet. Add them here as they are raised.

Related

  • #437: Meshtastic 2.8.x firmware support
  • #319: retire v1 ingest URLs
  • #83: per-observation forwarded-by
Lenguaje dominante
Python
Estrellas
1
Forks
0
Merge medio
1 d 20 h
PR fusionados (30 d)
5

Preparar el entorno

  • Incluye un Dockerfile o un archivo de Docker Compose
  • Tiene una plantilla de pull request
  • Sin guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de pskillen/meshflow-api

Todos los issues de pskillen/meshflow-api

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.