key4hep / key4hep-spack

A Spack recipe repository of Key4hep software.
10 stars 23 forks source link

Add py-rich per user request #601

Open tmadlener opened 3 months ago

tmadlener commented 3 months ago

BEGINRELEASENOTES

ENDRELEASENOTES

jmcarcell commented 3 months ago

For doing what? This is for something that is using rich I imagine (in contrast to a user wanting it for himself)

tmadlener commented 3 months ago

AFAIU for writing nicer output of some scripts. But I am also not sure where we want to draw the border for the python packages, as in principle they can also be installed on top of a key4hep stack via pip.

Tagging @Victor-Schwan here as well to get input from the original request.

Victor-Schwan commented 3 months ago

"Rich is a Python library for writing rich text (with color and style) to the terminal, and for displaying advanced content such as tables, markdown, and syntax highlighted code." https://rich.readthedocs.io/en/stable/introduction.html

Where you draw the line with the packages is of course a subjective decision. If you add packages more generously, everything works after sourcing key4hep regardless of the machine or personal environments.

Personally, I find 'rich' useful for formatting the output in more complex programs to keep an overview and actually find the stuff you are looking for.

jmcarcell commented 3 months ago

Personally, I find 'rich' useful for formatting the output in more complex programs to keep an overview and actually find the stuff you are looking for.

I'm not against it (and I estimate 3-5 new packages in python will be pulled for this) but I have used rich before and if it's for end-user scrips, like analysis scripts, then I would discourage its usage since if someone else has to run it then it's an extra dependency. For frameworks / tools that rely a lot on the terminal I think it's fine.