Skip to content

logging with RichHandler #2099

@bphunter1972

Description

@bphunter1972

I'm pretty surprised this isn't functioning as expected when running textual run --dev.

The messages make it to the screen, but they are all garbled.

image

I know about textual.log, but as I am adding a TUI front-end to another tool (which itself uses rich logging), I cannot readily swap it out.

Textual diagnosis:

Textual Diagnostics

Versions

Name Value
Textual 0.15.1
Rich 13.3.2

Python

Name Value
Version 3.8.10
Implementation CPython
Compiler Clang 6.0 (clang-600.0.57)
Executable /Users/bphunter/Library/Caches/pypoetry/virtualenvs/gviz-AtLwRJRq-py3.8/bin/python

Operating System

Name Value
System Darwin
Release 22.3.0
Version Darwin Kernel Version 22.3.0: Mon Jan 30 20:42:11 PST 2023; root:xnu-8792.81.3~2/RELEASE_X86_64

Terminal

Name Value
Terminal Application iTerm.app (3.4.19)
TERM xterm-256color
COLORTERM truecolor
FORCE_COLOR Not set
NO_COLOR Not set

Rich Console options

Name Value
size width=164, height=89
legacy_windows False
min_width 1
max_width 164
is_terminal True
encoding utf-8
max_height 89
justify None
overflow None
no_wrap False
highlight None
markup None
height None

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