i3 / i3

A tiling window manager for X11
https://i3wm.org/
BSD 3-Clause "New" or "Revised" License
9.55k stars 778 forks source link

libi3 error IPC received EOF instead of reply #1252

Closed i3bot closed 10 years ago

i3bot commented 10 years ago

[Originally reported by i3-new-ticket] (Hello,

My Specs:

Slackware 14.1 x86_64 i3 4.7.2 i3status 2.8 dmenu 4.5 xorg-server-1.14.3 Nvidia GTX660M - drivers 331.67

I see this message when I log out of i3 to the console;

libi3 error IPC received EOF instead of reply

Since it's saying 'error' I wanted to report this, I have no idea where it's coming from, and i3 seems to be running just fine. But seeing it say an error, I thought I should report this if it's a bug, and hopefully this can be figured out and fixed.

stapelberg commented 10 years ago

This is fine. When you log out of i3, i3 closes all IPC connections, so the libraries get an error and programs connected to i3 die. This is all expected. If you feel strongly about not seeing an error, feel free to send patches to http://cr.i3wm.org/

i3bot commented 10 years ago

[Original comment by anonymous]

I just noticed when I use this script to toggle/hide the statusbar it's also giving me the same types of error messages...

!/bin/bash

if [[ -z $(i3-msg -t get_bar_config bar-0 | grep invisible) ]] then i3-msg bar mode invisible & else i3-msg bar mode dock & fi exit 0

I'll see the messages like this toggling/hide the statusbar;

06/05/2014 04:29:04 PM - [libi3] ERROR: IPC received EOF instead of reply [{"success":true}] 06/05/2014 04:29:04 PM - [libi3] ERROR: IPC received EOF instead of reply window id as int = 23068675

Now that I see this message playing with the statusbar I get the feeling the original message I see when logging out is due to the statusbar as well.

Below is my conf I'm using;


This file has been auto-generated by i3-config-wizard(1).

It will not be overwritten, so edit it as you like.

#

Should you change your keyboard layout somewhen, delete

this file and re-run i3-config-wizard(1).

#

i3 config file (v4)

#

Please see http://i3wm.org/docs/userguide.html for a complete reference!

set $mod Mod4

Font for window titles. Will also be used by the bar unless a different font

is used in the bar {} block below. ISO 10646 = Unicode

font -misc-fixed-medium-r-normal--13-120-75-75-C-70-iso10646-1

The font above is very space-efficient, that is, it looks good, sharp and

clear in small sizes. However, if you need a lot of unicode glyphs or

right-to-left text rendering, you should instead use pango for rendering and

chose a FreeType font, such as:

font pango:DejaVu Sans Mono 10

font pango:Aller Light 9

Use Mouse+$mod to drag floating windows to their wanted position

floating_modifier $mod

start a terminal

bindsym $mod+Return exec i3-sensible-terminal

kill focused window

bindsym $mod+Shift+q kill #(Original binding)

bindsym $mod+q kill

start dmenu (a program launcher)

bindsym $mod+d exec --no-startup-id dmenu_run -fn 'Aller Light-9.5'

There also is the (new) i3-dmenu-desktop which only displays applications

shipping a .desktop file. It is a wrapper around dmenu, so you need that

installed.

bindsym $mod+d exec --no-startup-id i3-dmenu-desktop

change focus

bindsym $mod+j focus left bindsym $mod+k focus down bindsym $mod+l focus up bindsym $mod+semicolon focus right

alternatively, you can use the cursor keys:

bindsym $mod+Left focus left bindsym $mod+Down focus down bindsym $mod+Up focus up bindsym $mod+Right focus right

move focused window

bindsym $mod+Shift+j move left bindsym $mod+Shift+k move down bindsym $mod+Shift+l move up bindsym $mod+Shift+semicolon move right

alternatively, you can use the cursor keys:

bindsym $mod+Shift+Left move left bindsym $mod+Shift+Down move down bindsym $mod+Shift+Up move up bindsym $mod+Shift+Right move right

split in horizontal orientation

bindsym $mod+h split h

split in vertical orientation

bindsym $mod+v split v

enter fullscreen mode for the focused container

bindsym $mod+f fullscreen

change container layout (stacked, tabbed, toggle split)

bindsym $mod+s layout stacking bindsym $mod+w layout tabbed bindsym $mod+e layout toggle split

toggle tiling / floating

bindsym $mod+Shift+space floating toggle

change focus between tiling / floating windows

bindsym $mod+space focus mode_toggle

focus the parent container

bindsym $mod+a focus parent

focus the child container

bindsym $mod+d focus child

switch to workspace

bindsym $mod+1 workspace 1 bindsym $mod+2 workspace 2 bindsym $mod+3 workspace 3 bindsym $mod+4 workspace 4 bindsym $mod+5 workspace 5 bindsym $mod+6 workspace 6 bindsym $mod+7 workspace 7 bindsym $mod+8 workspace 8 bindsym $mod+9 workspace 9 bindsym $mod+0 workspace 10

move focused container to workspace

bindsym $mod+Shift+1 move container to workspace 1 bindsym $mod+Shift+2 move container to workspace 2 bindsym $mod+Shift+3 move container to workspace 3 bindsym $mod+Shift+4 move container to workspace 4 bindsym $mod+Shift+5 move container to workspace 5 bindsym $mod+Shift+6 move container to workspace 6 bindsym $mod+Shift+7 move container to workspace 7 bindsym $mod+Shift+8 move container to workspace 8 bindsym $mod+Shift+9 move container to workspace 9 bindsym $mod+Shift+0 move container to workspace 10

reload the configuration file

bindsym $mod+Shift+c reload

restart i3 inplace (preserves your layout/session, can be used to upgrade i3)

bindsym $mod+Shift+r restart

exit i3 (logs you out of your X session)

bindsym $mod+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -b 'Yes, exit i3' 'i3-msg exit'"

resize window (you can also use the mouse for that)

mode "resize" {

These bindings trigger as soon as you enter the resize mode

    # Pressing left will shrink the window’s width.
    # Pressing right will grow the window’s width.
    # Pressing up will shrink the window’s height.
    # Pressing down will grow the window’s height.
    bindsym j resize shrink width 10 px or 10 ppt
    bindsym k resize grow height 10 px or 10 ppt
    bindsym l resize shrink height 10 px or 10 ppt
    bindsym semicolon resize grow width 10 px or 10 ppt

    # same bindings, but for the arrow keys
    bindsym Left resize shrink width 10 px or 10 ppt
    bindsym Down resize grow height 10 px or 10 ppt
    bindsym Up resize shrink height 10 px or 10 ppt
    bindsym Right resize grow width 10 px or 10 ppt

    # back to normal: Enter or Escape
    bindsym Return mode "default"
    bindsym Escape mode "default"

}

bindsym $mod+r mode "resize"

Start i3bar to display a workspace bar (plus the system information i3status

finds out, if available)

bar { status_command i3status }

RULES FOR SPECIFIC APPLICATIONS

by APPLICATION (WM_CLASS)

Note: class is typically useful for applying custom settings to

to entire applications, including child windows. If this

isn't want you want see the ROLE section, below.

Tip: To find out what these values might be run:

xprop | grep -i 'class'

for_window [class="Bleachbit"] floating enable border pixel 1 for_window [class="CMST - Connman System Tray"] floating enable border pixel 1 for_window [class="Deadbeef"] floating enable border pixel 1 for_window [class="feh"] floating enable border pixel 1 for_window [class="Firefox"] floating enable border pixel 1 for_window [class="Fslint-gui"] floating enable border pixel 1 for_window [class="Geany"] floating enable for_window [class="Ghb"] floating enable border pixel 1 for_window [class="Gimp"] floating enable for_window [class="Hexchat"] floating enable border pixel 1 for_window [class="URxvt"] border pixel 1 for_window [class="Keepassx"] floating enable border pixel 1 for_window [class="Kid3-qt"] floating enable border pixel 1 for_window [class="Lxappearance"] floating enable border pixel 1 for_window [class="mpv"] floating enable border pixel 1 for_window [class="Nvidia-settings"] floating enable border pixel 1 for_window [class="Qpdfview"] floating enable border pixel 1 for_window [class="Spacefm"] floating enable border pixel 1 for_window [class="Steam"] floating enable for_window [class="Transmission-gtk"] floating enable border pixel 1 for_window [class="URxvt" title="(?i)(weechat|htop)"] floating enable, border pixel 1 for_window [class="Viewnior"] floating enable border pixel 1 for_window [class="VirtualBox"] floating enable border pixel 1 for_window [class="XCalc"] floating enable for_window [class="Xfce4-notifyd-config"] floating enable border pixel 1 for_window [class="Xfce4-notifyd"] floating enable border pixel 1 for_window [class="Yad"] floating enable

by ROLE (WM_WINDOW_ROLE)

Note: window_role is Typically useful for effecting child windows

such as instant messaging converstations, email composition

windows, etc.

Tip: To find out what these values might be run:

xprop | grep -i 'role'

for_window [window_role="conversation"] floating enable, border normal for_window [window_role="Msgcompose"] floating enable, border normal

RULES FOR KEY SHORTCUT APPLICATION START

bindsym $mod+F1 exec --no-startup-id feh --zoom fill -g 800x600 "/home/foo/Wallpaper/" bindsym $mod+F2 exec --no-startup-id urxvt -geometry 120x35 -e weechat bindsym $mod+F12 exec --no-startup-id /home/foo/.i3/scripts/i3exit.sh bindsym $mod+F11 exec --no-startup-id sudo /root/.urxvtcd bindsym $mod+b exec --no-startup-id /home/foo/.i3/scripts/toggle_bar.sh

AUTOSTART APPLICATIONS

exec --no-startup-id /home/foo/.conky/conky_start.sh

exec --no-startup-id /usr/bin/xbindkeys

stapelberg commented 10 years ago

Replying to comment 2 by anonymous:

#!/bin/bash
if [[ -z $(i3-msg -t get_bar_config bar-0 | grep invisible) ]]
then i3-msg bar mode invisible &
else i3-msg bar mode dock &
fi
exit 0

Why the & at the end of the commands?

The error message appears every time an IPC client disconnects. Again, if you care, submit a patch.

i3bot commented 10 years ago

[Original comment by anonymous]

Hi michael,

Sorry I've just started using i3 so I'm a bit new here to what is going on.

I didn't make the dock hide script I just found it online.

What is/are these IPC clients, since I'm only logging out of i3 is all of this normal, if it is, then why have it fill up the console if this is not an error?

I'm not a coder, but it would really be great if this could be patched not to fill the console if it's not important.

thank you

i3bot commented 10 years ago

[Original comment by anonymous]

Forgot to mention, these messages are really flooding the console;

window id as int = 23068675

I personally need to use my console logging back and forth from i3 for various reasons and I need to see what's going on with my console, and it makes it really hard have it flooded with messages like this window id...

I hope in time the i3 developers can please fix this, not sure there's any reaon to see these messages?

thank you very much

i3bot commented 10 years ago

[Original comment by anonymous]

Sorry michael, I see you explained the IPC;

This is fine. When you log out of i3, i3 closes all IPC connections, so the libraries get an error and programs connected to i3 die. This is all expected. If you feel strongly about not seeing an error, feel free to send patches to ​http://cr.i3wm.org/

Ok so if this is all fine and normal, then why even log it to the console and call it an error? Sorry if I'm seeming dense here, but all the things I've learned in Linux, errors are not normal and anything normal isn't typically then logged calling it an error.

As I mentioned, if it's all fine and normal, then why even have this log to the console, seems pointless, no?

Again thank you very much for your time and help in this matter, but I truly hope the i3 team can please get these messages, along with the window id as int = from filling the console, since it seems unnecessary

i3bot commented 10 years ago

[Original comment by anonymous]

I'm also getting a lot of this constantly flooding the console too;

rect now: (0,0,0,0) rect now: (0,0,0,0) rect now: (0,0,0,0) rect now: (0,0,0,0) append tree using root new root =0x1ed29d0 out = 0x1ed29d0 ws = 0x1ed3570

windows id as int =29360131 windows id as int =32325568 windows id as int =65354543 windows id as int =43243433 windows id as int =65656634

The rect now: sections really get crazy with mass amounts of this going on...

thanks again...

i3bot commented 10 years ago

[Original comment by Tony Crisci]

This ticket was fixed in commit http://c.i3wm.org/7e564713:

Don't ELOG ipc EOF

Receiving EOF from a client is not an error, but rather a standard way a
client may disconnect from the IPC. This should rather be logged from
a consumer of the libi3 ipc_recv_message() function as a normal client
disconnect event.

fixes #1252
stapelberg commented 10 years ago

This ticket was fixed in commit http://c.i3wm.org/617afc67:

replace remaining printf()s with D?LOG

fixes #1252
i3bot commented 10 years ago

[Original comment by anonymous]

I just patched i3 and these two patches appear to be working great!

Nice clean tty/console! :)

THANKS

i3bot commented 10 years ago

[Original comment by anonymous]

Regarding stopping logging to the tty/console I'm also seeing these messages;

[i3bar/src/xcb.c:528] ERROR window 01a0004b violates the XEMBED Protocol _XEMBED_INFO not set

Should these types of messages also been cleaned up and not logging out to the tty/console?

Thank you

i3bot commented 10 years ago

[Original comment by anonymous]

I just noticed the console is also filling up with massive amounts of these messages too, which I thought would no longer be sent to the console with this patch;

rect now: (0,0,0,0) rect now: (0,0,0,0) rect now: (0,0,0,0) rect now: (0,0,0,0)

stapelberg commented 10 years ago

[i3bar/src/xcb.c:528] ERROR window 01a0004b violates the XEMBED Protocol _XEMBED_INFO not set Should these types of messages also been cleaned up and not logging out to the tty/console? No, those are errors.

rect now: (0,0,0,0) I don’t see these. Are you sure you use the most recent version? Grepping for “rect now” in the source reveals only one location, and there we use DLOG, so it will not appear on your console.

i3bot commented 10 years ago

[Original comment by anonymous]

most recent version, yes 4.7.2

stapelberg commented 10 years ago

4.7.2 is not the most recent version. Run i3 --moreversion. You should get an output like this:

Binary i3 version:  4.7.2-191-g8ece995 (2014-06-11, branch "next") © 2009-2014 Michael Stapelberg and contributors
Running i3 version: 4.7.2-191-g8ece995 (2014-06-11, branch "next") (pid 3105)

Otherwise, you don’t have the necessary commit.

i3bot commented 10 years ago

[Original comment by anonymous]

I was thinking most recent version...

I'll clone from git...

thanks

i3bot commented 10 years ago

[Original comment by anonymous]

Next from GIT is very buggy, to much for me to deal with on a production machine.

I need to just stick to 4.7.2 it's a lot more stable, for now all I'm concerned with is all the info that's getting spewed to the console, otherwise things are running much better...

I'm going to install 4.7.2 back and let you know how these patches work.

Thanks

stapelberg commented 10 years ago

What?! the version that’s currently in “next” is supposed to be released as-is in a few days. If you see any bugs that you have not seen in 4.7.2, please report them ASAP!

i3bot commented 10 years ago

[Original comment by anonymous]

http://bugs.i3wm.org/query/ticket/1260

i3bot commented 10 years ago

[Original comment by TonyC]

This is fixed. Make a new issue on the bug tracker for other issues.

i3bot commented 10 years ago

[Original comment by anonymous]

The console is filling up again with different messages, I thought releated to not having it do?

These messages I reported on #1261 also fill up the tty/console

http://bugs.i3wm.org/query/ticket/1261

ERROR: No output found at destination coordinates, centering floating window on current ws

i3bot commented 10 years ago

[Original comment by anonymous]

Sorry #1264

i3bot commented 10 years ago

[Original comment by anonymous]

Hi TonyC,

I'm trying to not make this confusing, originally it was about a message, but it was also about that message filling up in the console, and later I kept replying to this post about more messages I started to see filling up in the console after I originally posted this, and I've now noticed this happening for the message in #1264 going to the console.

I just wanted to clarify this, I didn't think to open up other reports just to get messages out of the console.

THANKS

stapelberg commented 10 years ago

Please don’t keep reopening tickets, this is really annoying.

If you see ERRORs on your console, those are ERRORs. It is intended that they show up.

We have eliminated all printf()s that could write directly to your console. This bug is fixed. This is my last word on this bug.

i3bot commented 10 years ago

[Original comment by anonymous]

Sorry I'm trying my best here...

thanks