Toqozz / wired-notify

Lightweight notification daemon with highly customizable layout blocks, written in Rust.
MIT License
608 stars 28 forks source link

Persistant error after trying to use `print_to_file` #82

Closed lukelex closed 2 years ago

lukelex commented 2 years ago

Seem to be fixed after a reboot.

Wired 0.10.2-1 from AUR.

$ RUST_BACKTRACE=full wired
A wired socket exists; taking ownership.  Existing wired processes will not receive CLI calls.
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Os { code: 1, kind: PermissionDenied, message: "Operation not permitted" }', src/cli.rs:47:47
stack backtrace:
   0:     0x5564a11db22d - <unknown>
   1:     0x5564a1201a4c - <unknown>
   2:     0x5564a11d7d41 - <unknown>
   3:     0x5564a11dcc45 - <unknown>
   4:     0x5564a11dc966 - <unknown>
   5:     0x5564a0e3ad1e - <unknown>
   6:     0x5564a11dd28a - <unknown>
   7:     0x5564a11dd0c7 - <unknown>
   8:     0x5564a11db6e4 - <unknown>
   9:     0x5564a11dcdf9 - <unknown>
  10:     0x5564a0dfc6e3 - <unknown>
  11:     0x5564a0dfc7d3 - <unknown>
  12:     0x5564a0e273f3 - <unknown>
  13:     0x5564a0e3a89c - <unknown>
  14:     0x5564a0e35053 - <unknown>
  15:     0x5564a0e5ea19 - <unknown>
  16:     0x5564a11d2c16 - <unknown>
  17:     0x5564a0e3ad52 - <unknown>
  18:     0x7fc31bbc8290 - <unknown>
  19:     0x7fc31bbc834a - __libc_start_main
  20:     0x5564a0dfc985 - <unknown>
  21:                0x0 - <unknown>
Toqozz commented 2 years ago

What happened leading up to this? It looks like we panicked trying to remove the old socket file -- permission denied. This could happen if you accidentally ran wired as root or something. A restart fixes it because /tmp gets cleared on restart. You could also manually remove the file and it would be fine.

I'll add a note to the panic about removing the file manually and explaining the issue, but otherwise there's no way we can really handle this.

lukelex commented 2 years ago

I was playing with user groups and running processes with different users. So that explains it all :sweat_smile: