Skip to content

close button + wordwrap details pane - #77

Open
tomdeblauwe wants to merge 8 commits into
Textualize:mainfrom
tomdeblauwe:main
Open

close button + wordwrap details pane#77
tomdeblauwe wants to merge 8 commits into
Textualize:mainfrom
tomdeblauwe:main

Conversation

@tomdeblauwe

@tomdeblauwe tomdeblauwe commented Jul 7, 2026

Copy link
Copy Markdown
  • Add clickable close button
  • Scroll speed improvements
  • Allow to wordwrap the details pane
  • Tested with textual 8.2.4

@mattviasat

mattviasat commented Jul 22, 2026

Copy link
Copy Markdown

I got the following error after trying you branch. This was in a venv with nothing else installed.
The version of textual is 0.58.1, which is what got installed by default.

I even tried it with a very simple json.

echo '{"hello":"world"}' | tl
/tmp/3tmp/lib/python3.14/site-packages/textual/message_pump.py:605: RuntimeWarning: coroutine 'LogFooter.mount_keys' was never awaited
  await self._flush_next_callbacks()
RuntimeWarning: Enable tracemalloc to get the object allocation traceback
^[[?2026;2$y╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────── Traceback (most recent call last) ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ /tmp/3tmp/lib/python3.14/site-packages/toolong/log_view.py:269 in watch_can_tail                                                                                                                                                                                                                               │
│                                                                                                                                                                                                                                                                                                                │
│   266 │   │   self.query(".tail").set_class(tail and self.can_tail, "on")                      ╭──────── locals ────────╮                                                                                                                                                                                      │
│   267 │                                                                                        │ can_tail = False       │                                                                                                                                                                                      │
│   268 │   async def watch_can_tail(self, can_tail: bool) -> None:                              │     self = LogFooter() │                                                                                                                                                                                      │
│ ❱ 269 │   │   await self.mount_keys()                                                          ╰────────────────────────╯                                                                                                                                                                                      │
│   270 │                                                                                                                                                                                                                                                                                                        │
│   271 │   def watch_filename(self, filename: str) -> None:                                                                                                                                                                                                                                                     │
│   272 │   │   self.update_meta()                                                                                                                                                                                                                                                                               │
│                                                                                                                                                                                                                                                                                                                │
│ /tmp/3tmp/lib/python3.14/site-packages/toolong/log_view.py:231 in mount_keys                                                                                                                                                                                                                                   │
│                                                                                                                                                                                                                                                                                                                │
│   228 │   │   │   │   await key_container.query("*").remove()                                  ╭─────────── locals ───────────╮                                                                                                                                                                                │
│   229 │   │   │   │   bindings = [                                                             │ key_container = Horizontal() │                                                                                                                                                                                │
│   230 │   │   │   │   │   binding                                                              │          self = LogFooter()  │                                                                                                                                                                                │
│ ❱ 231 │   │   │   │   │   for (_, binding, *_rest) in self.app.active_bindings.values()        ╰──────────────────────────────╯                                                                                                                                                                                │
│   232 │   │   │   │   │   if binding.show                                                                                                                                                                                                                                                                      │
│   233 │   │   │   │   ]                                                                                                                                                                                                                                                                                        │
│   234                                                                                                                                                                                                                                                                                                          │
╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
AttributeError: 'UI' object has no attribute 'active_bindings'

NOTE: 1 of 4 errors shown. Run with textual run --dev to see all errors.

I cannot install textual==8.2.4 because of

ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
toolong 1.5.0 requires textual<0.59.0,>=0.58.0, but you have textual 8.2.4 which is incompatible.
Successfully installed platformdirs-4.11.0 textual-8.2.4

You need to change the pyproject.toml to require the newer version of textual.

When I did install the new textual, it did work, but I didn't see long lines wrapping. I only saw the scroll bar disappear

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants