Breaking `postcard` version updates cause unclear version mismatch error

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

Los mantenedores suelen responder en 2 días

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
5/5
Tiempo estimado
Más de una semana
Aptitud para principiantes
25/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
rust
Área
api, networking

Línea de trabajo

Start by reviewing the OpteCmdIoctl structure, the DeserCmdErr and Error implementations, and how opteadm and sled-agent consume these errors. Determine how version mismatches currently fail and define a clearer API failure mode, with tests or consumer behavior demonstrating that the mismatch is identifiable.

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

Descripción

bug

As seen in omicron#4414, upgrading the version of postcard from 0.x -> 1.x leads to mutual unintelligibility between OPTE 0.25 and 0.26. There is every possibility this could happen again in future: either via postcard 2.0, or we might choose another wire format.

We can probably:

  • make this error clearer in the API surface (i.e., indicate in our Error impl that a DeserCmdErr may well be an API version mismatch). The two main consumers here are opteadm and sled-agent, most likely.
  • move one or more fields outside of the OpteCmdIoctl struct: api_version being the obvious one, or we could prepend a separate wire-format version. This would still cause another messy break in parse behaviour, so we'd need to combine it with some clarifiaction of the failure mode.
Lenguaje dominante
Rust
Estrellas
82
Forks
16
Merge medio
3 d 6 h
PR fusionados (30 d)
11

Preparar el entorno

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 oxidecomputer/opte

Todos los issues de oxidecomputer/opte

Issues similares

Más issues de Rust

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.