probonopd / go-appimage

Go implementation of AppImage tools
MIT License
680 stars 69 forks source link

Panics when user is created by systemd-homed #238

Closed ananthb closed 1 year ago

ananthb commented 1 year ago

Screenshot from 2022-12-24 22-47-52

appimaged panics if the current user is created and managed by systemd-homed.

Upstream Go issue: https://github.com/golang/go/issues/38810

CalebQ42 commented 1 year ago

Same issue we #215. Should be fixed in #235

probonopd commented 1 year ago

Thanks @CalebQ42, out of curiosity, what causes this and what is the fix?

CalebQ42 commented 1 year ago

It's simply that user.Current() only searches /etc/passwd for users and if the UID doesn't appear there, it returns an error. ATM the function that calls it doesn't do anything anyway, so I just changed it so it just returns instead of panicing.

ananthb commented 1 year ago

To add on, I'm working on fixing this in Go: https://go-review.googlesource.com/c/go/+/459455#message-3958c74d8449858b65ac2e73be1e078238e9f3b0

ananthb commented 1 year ago

Duplicate of #215