Textualize / rich

Rich is a Python library for rich text and beautiful formatting in the terminal.
https://rich.readthedocs.io/en/latest/
MIT License
48.1k stars 1.69k forks source link

Adds a `name` attribute to `Spinner` #3359

Open KaiSforza opened 1 month ago

KaiSforza commented 1 month ago

Makes it nicer for validation and use of the Spinner object in later functions/classes.

Type of changes

Checklist

Description

Simply adds a name attribute to Spinner for use in later functions/classes. The current one has no mention of name outside of __init__, but a lot of the functions and classes take a spinner name, not a spinner object. I added this because of some of the stuff I did in pypa/hatch#1490. Would have been nice to make it not a throwaway.

willmcgugan commented 1 day ago

I don't quite follow why you need this. Can you elaborate?