Displaying output that is re-written on the same lines
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 35/100
Direzione di ricerca
No files or tests are named. Start by tracing how pyinvoke captures and prints subprocess output for the shown docker compose command, then compare its handling of carriage returns and other control characters with direct terminal output. Done means supported output is rendered with the same in-place updates without breaking existing command output behavior.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
I'm trying to execute docker compose up -d --force-recreate --remove-orphans command via pyinvoke. The command outputs such that it updates on the same lines using control characters. But when executing via pyinvoke, it prints all the lines on separate lines.
Is it possible to have the output printed exactly as by the command?
Example:
docker-compose output (it does print logs for creating containers, but it is over-written by newer logs on the same line):
docker compose up -d --force-recreate --remove-orphans
[+] Running 3/3
⠿ Network test_app_default Created 0.1s
⠿ Container test_app-redis-1 Started 1.3s
⠿ Container test_app-web-1 Started 1.2s
same using pyinvoke:
docker compose up -d --force-recreate --remove-orphans
Network test_app_default Creating
Network test_app_default Created
Container test_app-redis-1 Creating
Container test_app-web-1 Creating
Container test_app-redis-1 Created
Container test_app-web-1 Created
Container test_app-redis-1 Starting
Container test_app-web-1 Starting
Container test_app-web-1 Started
Container test_app-redis-1 Started
Of course I could add the --no-ansi flag to docker-compose, but I was wondering if we can achieve this effect via pyinvoke as well.
Thanks!
- Lingua principale
- Python
- Stelle
- 4.8k
- Fork
- 412
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di pyinvoke/invoke
-
[Security] Shell injection via Context.cd() path argument — metacharacters not escaped (CWE-78) Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 64/100
Tutte le issue di pyinvoke/invoke
Issue simili
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
xinnan-tech/xiaozhi-fde-talk#263 ·
-
rules
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
huggingface/Repo2RLEnv#163 · 1 commento ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 95/100
huggingface/sentence-transformers#4074 ·
-
comp/dashboard invalid P3
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
NousResearch/hermes-agent#121143 ·