question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

IOError: [Errno 25] Ioctl() Inappropriate ioctl for device

See original GitHub issue

Hi, this issue appeared recently (even with latest .gdbinit):

Cannot write the dashboard
Traceback (most recent call last):
  File "<string>", line 516, in render
  File "<string>", line 608, in get_term_size
IOError: [Errno 25] Ioctl() Inappropriate ioctl for device

As a workaround I have added IOError to the exception handling of get_term_size and hardcoded my usual terminal size. According to gdb’s python-interactive console, sys.platform = 'linux2' on my system (Ubuntu 20.04).

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:13 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
cyrus-andcommented, Mar 24, 2022

In the meantime, a probably better workaround that respects the actual terminal size, would be to replace 1 with 0 or 2, in the following, since your stdin and stderr files still point to the TTY.

https://github.com/cyrus-and/gdb-dashboard/blob/13df4b1267b6cf3545601db0ac5c872317beb189/.gdbinit#L597

0reactions
cyrus-andcommented, Mar 28, 2022

That makes sense, so I guess you can easily fix that. Thanks for letting me know.

Read more comments on GitHub >

github_iconTop Results From Across the Web

IOError: [Errno 25] Inappropriate ioctl for device - Stack Overflow
This generally means something is capturing stdout (eg: pytest). In which case shutil.get_terminal_size().columns will return 80 .
Read more >
OSError: [Errno 25] Inappropriate ioctl for device - Get Help
Changed from Pi zero W to pi4b external. What did you already try to solve it? Checked my wiring for tx and rx,...
Read more >
[Errno 25] Inappropriate ioctl for device #6980 - iterative/dvc
We are running a Linux machine (X large) on CircleCi. The error happens after our job runs dvc pull -r s3-remote . Any...
Read more >
serial errno 25 inappropriate ioctl for device
I have raspberry pi 3 B+ running latest raspbian-strech lite. i have a max485 ic connected to uart on the gpio. import serial,fcntl,...
Read more >
Fixing [Errno 25] Inappropriate ioctl for device - Ahmet Ertem
My search results showing (mostly) error source is terminal output or terminal output is redirected another app etc. I didn't get suspicius ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found