Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

`humility ringbuf list` table is misaligned when a ringbuf has a long path

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

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
2/5
Tiempo estimado
1-3 horas
Aptitud para principiantes
55/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
rust
Área
cli, devtools

Línea de trabajo

Comienza con el comando humility ringbuf list y reproduce la salida usando un Gimlet o las rutas ringbuf largas mostradas en el informe. Comprueba el formato de la tabla y verifica que ADDR y SIZE permanezcan alineados cuando las rutas superen los 30 caracteres, mientras se conserva el diseño existente para rutas cortas.

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

Descripción

If the path to a ringbuf is longer than 30 characters, the ADDR and SIZE columns in the table printed by humility ringbuf list aren't aligned nicely. And, it turns out that when building Humility for a Gimlet, there are several ringbufs with paths longer than 30 characters:

eliza@cadbury ~ $ pfexec humility -t c71 ringbuf --list
humility: attached to 0483:3754:001100184741500820383733 via ST-Link V3
MODULE             BUFFER                         ADDR       SIZE
gimlet_seq         drv_gimlet_seq_server::__RINGBUF 0x2403e640 3088
power              drv_i2c_devices::adm1272::__RINGBUF 0x2403d500 652
thermal            drv_i2c_devices::max31790::__RINGBUF 0x24003770 84
sbrmi              drv_i2c_devices::sbrmi::__RINGBUF 0x2404d4ec 252
gimlet_seq         drv_oxide_vpd::__RINGBUF       0x2403f250 108
host_sp_comms      drv_oxide_vpd::__RINGBUF       0x24021ab0 108
gimlet_seq         drv_packrat_vpd_loader::__RINGBUF 0x2403f2bc 588
sbrmi              drv_sbrmi::__RINGBUF           0x2404d320 460
spi2_driver        drv_stm32h7_spi_server_core::__RINGBUF 0x24048368 1036
sprot              drv_stm32h7_spi_server_core::__RINGBUF 0x24034000 1036
sprot              drv_stm32h7_sprot_server::__RINGBUF 0x2403440c 1804
i2c_driver         drv_stm32xx_i2c::__RINGBUF     0x24049bb4 780
spd                drv_stm32xx_i2c::__RINGBUF     0x2404a48c 780
i2c_driver         drv_stm32xx_i2c_server::__RINGBUF 0x24049380 2100
net                ksz8463::__RINGBUF             0x24019628 268
host_sp_comms      ksz8463::__RINGBUF             0x24027c9c 268
update_server      stm32h7_update_server::__RINGBUF 0x24045800 1036
control_plane_agent task_control_plane_agent::CRITICAL 0x2402b850 656
control_plane_agent task_control_plane_agent::__RINGBUF 0x24029000 1040
control_plane_agent task_control_plane_agent::update::rot::__RINGBUF 0x2402b244 1548
dump_agent         task_dump_agent::__RINGBUF     0x24038960 60
dump_agent         task_dump_agent::udp::__RINGBUF 0x240389a0 528
hiffy              task_hiffy::stm32h7::__RINGBUF 0x24008408 1548
host_sp_comms      task_host_sp_comms::__RINGBUF  0x24021000 2736
jefe               task_jefe::dump::__RINGBUF     0x2404c600 236
jefe               task_jefe::external::__RINGBUF 0x2404c6ec 60
net                task_net::mgmt::__RINGBUF      0x24012158 528
packrat            task_packrat::__RINGBUF        0x24006380 656
power              task_power::__RINGBUF          0x2403c9c8 44
power              task_power::bsp::__RINGBUF     0x2403c9f4 2828
spd                task_spd::__RINGBUF            0x2404a380 268
thermal            task_thermal::__RINGBUF        0x240039e0 784
validate           task_validate::__RINGBUF       0x240443e8 1036
net                vsc85xx::__RINGBUF             0x240197b4 204

Humility version:

eliza@cadbury ~ $ pfexec humility --version
humility 0.10.38

My guess is that the current lengths of these columns was selected to fit nicely in an 80-column terminal, which makes sense. But, when there are long paths, it's hard to read regardless of the terminal, and making the terminal wider doesn't help. We probably want to default to the current lengths, but scan the ringbuf paths first to see if there's any entry that's too long, and make it wider in that case?

Alternatively, since the address and size columns are almost always much shorter, we could just put them first, although I'll admit it's kinda weird to see the address and size without knowing what it is that you're looking at (as a right-to-left language reader)...

Lenguaje dominante
Rust
Estrellas
587
Forks
64
Merge medio
2 d 1 h
PR fusionados (30 d)
7

Preparar el entorno

Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

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/humility

Todos los issues de oxidecomputer/humility

Issues similares

Más issues de Rust

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.