stdbuf: -oL and -o0 have no effect on uniq

Aperta
#16,649 3 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
63/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
rust
Ambito
cli

Direzione di ricerca

Start by locating uniq's output handling and the implementation of stdbuf in the repository; the issue does not name source files or tests. Reproduce the reported pipeline with stdbuf -oL uniq and stdbuf -o0 uniq, then run bash util/build-gnu.sh && bash util/run-gnu-test.sh tests/misc/stdbuf.sh. Done means output arrives line by line as it does with GNU coreutils and the test passes.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

gnu testsuite good first issue U - stdbuf U - uniq

stdbuf -oL / stdbuf -o0 have no effect on uniq: its output is only flushed at exit.

$ (echo first; sleep 1; echo second) | stdbuf -oL uniq | while read l; do echo "$(date +%S) $l"; done

uutils: both lines arrive together after 1s.
GNU 9.12: first arrives immediately, second 1s later.

Same with -o0.

GNU test: bash util/build-gnu.sh && bash util/run-gnu-test.sh tests/misc/stdbuf.sh
It is listed in ignore-intermittent.txt, but it failed in all of the last 40 GnuTests runs.

Part of #14705

Lingua principale
Rust
Stelle
24.4k
Fork
2.2k
Merge medio
2g 23h
PR unite (30g)
402

Preparare l'ambiente

Apri in Codespaces

Avvia il container di sviluppo del progetto nel browser, con il tuo account GitHub.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di uutils/coreutils

Tutte le issue di uutils/coreutils

Issue simili

Altre issue su Rust

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.