Page MenuHomePhabricator

Cumin: replace colorama
Closed, ResolvedPublic

Description

In stretch there is a regression in colorama in conjunction with tqdm that leads to a slow down of the progress of the script proportional to the amount of data printed to stdout/err. Colorama starts having very huge stacktraces and the process is stuck at 100% CPU for an increasingly amount of time while more data is printed.

Given the very simple usage of colors that is made in Cumin as of now, it seems much more feasible to replace the colorama library (as all that cross-OS support is not needed) and add a simple module with ANSI escape sequence support.

Event Timeline

Volans triaged this task as High priority.Feb 25 2019, 2:24 PM
Volans created this task.

Change 481858 had a related patch set uploaded (by Volans; owner: Volans):
[operations/software/spicerack@master] remote: suppress Cumin's output

https://gerrit.wikimedia.org/r/481858

If only linux terminal support is needed, maybe something like tput would be a good way to approach this (this looks pretty neat: https://github.com/erikrose/blessings)

Change 481858 merged by Volans:
[operations/software/spicerack@master] remote: suppress Cumin's output

https://gerrit.wikimedia.org/r/481858

Change 524601 had a related patch set uploaded (by Volans; owner: Volans):
[operations/software/cumin@master] dependency: replace colorama with custom module

https://gerrit.wikimedia.org/r/524601

Change 524601 merged by jenkins-bot:
[operations/software/cumin@master] dependency: replace colorama with custom module

https://gerrit.wikimedia.org/r/524601