Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

`cf d1 migrations apply --local` does not exit while stdin is an open non-TTY pipe

Aperta
#64 0 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
68/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
bun, typescript
Ambito
cli

Direzione di ricerca

Start at the cf d1 migrations apply CLI entry point and run the provided cat | cf d1 migrations apply ... --local reproduction. Trace the command's lifecycle after migrations are applied, then verify it exits with an open non-TTY pipe as well as with a TTY and /dev/null.

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

Descrizione

Problem

cf d1 migrations apply <id> --local --persist-to <dir> prints that it applied the migrations, then does not exit while its stdin is an open non-TTY pipe (for example under a process supervisor or a script that runs it as a child with piped stdio). Under a TTY it exits, and it also exits with </dev/null. This may share a cause with #25, which hangs on a fresh state directory.

Reproduction

cat | cf d1 migrations apply 00000000000000000000000000000000 --local --persist-to /tmp/state --dir ./migrations

Migrations are applied, and the process keeps running until stdin closes.

Expected

The command exits after it finishes, whatever stdin is.

Environment

[email protected], macOS, Bun 1.4.2.

Lingua principale
TypeScript
Stelle
916
Fork
53
Merge medio
18h 26m
PR unite (30g)
177

Preparare l'ambiente

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 cloudflare/cf

Tutte le issue di cloudflare/cf

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.