Skip to content

Update TRL_USE_RICH flag for CLI #1800

@alvarobartt

Description

@alvarobartt

Description

Apparently the usage of rich when using trl's CLI is currently enforced to True (set to "1"), meaning that rich will always be used.

While this may be a nice enhancement to the CLI display to some, in some cases as logging to an external tracking tool as e.g. GCP's Log Explorer, makes the experience a bit hard since rich is not properly handled so no logs are propagated, as the tqdm bar is being updated.

So on, how the TRL_USE_RICH flag is defined and handled could be improved, so that it can be both enabled and disabled (at the moment it can only be enabled as per

TRL_USE_RICH = os.environ.get("TRL_USE_RICH", False)
, meaning that when set, no matter what value is is, the condition if TRL_USE_RICH will always be true).

Proposal

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions