IsmaelMartinez / teams-for-linux

Unofficial Microsoft Teams for Linux client
GNU General Public License v3.0
2.95k stars 240 forks source link

TFL has the wrong configPath on Ubuntu 24.04.1 #1422

Closed ak2766 closed 1 month ago

ak2766 commented 1 month ago

Describe the bug Since moving to Ubuntu 24.04.1, I cannot get TFL to load my config

To Reproduce Steps to reproduce the behavior:

  1. Install TFL snap package
  2. Start TFL - teams-for-linux --appLogLevels error,warn,info,debug
  3. Note the configPath configPath: /home/akk/snap/teams-for-linux/671/.config/teams-for-linux
  4. Note that configFile is empty configFile: {}

Expected behavior I expected:

  1. configPath to be configPath: /home/akk/.config/teams-for-linux
  2. configFile to show contents of my configFile from when I was using Ubuntu 22.04

Screenshots N/A

Desktop (please complete the following information):

Debug

$ > teams-for-linux --appLogLevels error,warn,info,debug
update.go:85: cannot change mount namespace according to change mount (/var/lib/snapd/hostfs/boot /boot none bind,ro 0 0): permission denied
No config file found, using default values
all good with appLogLevels you aren't using them
Initialising logger with config: "{}"
Logger initialised with transports: {}
11:01:19.106 › File logging at /home/akk/snap/teams-for-linux/671/.config/teams-for-linux/logs/main.log with level silly
11:01:19.107 › Console logging enabled with level silly
11:01:19.107 › Logger initialised
11:01:19.108 › configPath: /home/akk/snap/teams-for-linux/671/.config/teams-for-linux
11:01:19.108 › configFile: {}

The provide in this section the output from both the terminal and the browser debug console.

$ > teams-for-linux --webDebug --logConfig='{}'
No config file found, using default values
all good with appLogLevels you aren't using them
Initialising logger with config: "{}"
Logger initialised with transports: {}
11:12:45.174 › File logging at /home/akk/snap/teams-for-linux/671/.config/teams-for-linux/logs/main.log with level silly
11:12:45.177 › Console logging enabled with level silly
11:12:45.177 › Logger initialised
11:12:45.177 › configPath: /home/akk/snap/teams-for-linux/671/.config/teams-for-linux
11:12:45.177 › configFile: {}
dbus-send: /snap/teams-for-linux/671/lib/x86_64-linux-gnu/libdbus-1.so.3: version `LIBDBUS_PRIVATE_1.12.20' not found (required by dbus-send)

(teams-for-linux:2563551): Gtk-WARNING **: 11:12:45.240: Theme parsing error: gtk.css:1422:23: 'font-feature-settings' is not a valid property name

(teams-for-linux:2563551): Gtk-WARNING **: 11:12:45.243: Theme parsing error: gtk.css:3308:25: 'font-feature-settings' is not a valid property name

(teams-for-linux:2563551): Gtk-WARNING **: 11:12:45.243: Theme parsing error: gtk.css:3770:23: 'font-feature-settings' is not a valid property name
libGL error: MESA-LOADER: failed to open iris (search paths /snap/teams-for-linux/671/gnome-platform/usr/lib/x86_64-linux-gnu/dri)
libGL error: failed to load driver: iris
libGL error: MESA-LOADER: failed to open iris (search paths /snap/teams-for-linux/671/gnome-platform/usr/lib/x86_64-linux-gnu/dri)
libGL error: failed to load driver: iris
libGL error: MESA-LOADER: failed to open swrast (search paths /snap/teams-for-linux/671/gnome-platform/usr/lib/x86_64-linux-gnu/dri)
libGL error: failed to load driver: swrast
[2563638:0926/111245.338742:ERROR:angle_platform_impl.cc(44)] Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2563638:0926/111245.338888:ERROR:gl_display.cc(515)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.
[2563638:0926/111245.338968:ERROR:gl_display.cc(786)] eglInitialize OpenGL failed with error EGL_NOT_INITIALIZED, trying next display type
[2563638:0926/111245.339989:ERROR:angle_platform_impl.cc(44)] Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2563638:0926/111245.340123:ERROR:gl_display.cc(515)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.
[2563638:0926/111245.340144:ERROR:gl_display.cc(786)] eglInitialize OpenGLES failed with error EGL_NOT_INITIALIZED
[2563638:0926/111245.340255:ERROR:gl_display.cc(820)] Initialization of all EGL display types failed.
[2563638:0926/111245.340274:ERROR:gl_ozone_egl.cc(26)] GLDisplayEGL::Initialize failed.
[2563638:0926/111245.342336:ERROR:angle_platform_impl.cc(44)] Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2563638:0926/111245.342372:ERROR:gl_display.cc(515)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.
[2563638:0926/111245.342389:ERROR:gl_display.cc(786)] eglInitialize OpenGL failed with error EGL_NOT_INITIALIZED, trying next display type
[2563638:0926/111245.343479:ERROR:angle_platform_impl.cc(44)] Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2563638:0926/111245.343498:ERROR:gl_display.cc(515)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.
[2563638:0926/111245.343512:ERROR:gl_display.cc(786)] eglInitialize OpenGLES failed with error EGL_NOT_INITIALIZED
[2563638:0926/111245.343525:ERROR:gl_display.cc(820)] Initialization of all EGL display types failed.
[2563638:0926/111245.343540:ERROR:gl_ozone_egl.cc(26)] GLDisplayEGL::Initialize failed.
[2563638:0926/111245.344226:ERROR:viz_main_impl.cc(198)] Exiting GPU process due to errors during initialization
11:12:45.395 › processArgs: [
  '/snap/teams-for-linux/671/teams-for-linux',
  '--webDebug',
  '--logConfig={}',
  '--no-sandbox'
]
11:12:45.396 › testing RegExp processArgs false
11:12:45.396 › testing RegExp processArgs false
11:12:45.397 › testing RegExp processArgs false
11:12:45.397 › testing RegExp processArgs false
11:12:45.397 › Testing network using net.request() for https://teams.microsoft.com
11:12:45.398 › Spellchecker is disabled!
[2563551:0926/111245.421928:ERROR:object_proxy.cc(576)] Failed to call method: org.freedesktop.login1.Manager.Inhibit: object_path= /org/freedesktop/login1: org.freedesktop.DBus.Error.AccessDenied: An AppArmor policy prevents this sender from sending this message to this recipient; type="method_call", sender=":1.60740" (uid=1000 pid=2563551 comm="/snap/teams-for-linux/671/teams-for-linux --webDeb" label="snap.teams-for-linux.teams-for-linux (enforce)") interface="org.freedesktop.login1.Manager" member="Inhibit" error name="(unset)" requested_reply="0" destination="org.freedesktop.login1" (uid=0 pid=1663 comm="/usr/lib/systemd/systemd-logind" label="unconfined")
libGL error: MESA-LOADER: failed to open iris (search paths /snap/teams-for-linux/671/gnome-platform/usr/lib/x86_64-linux-gnu/dri)
libGL error: failed to load driver: iris
libGL error: MESA-LOADER: failed to open iris (search paths /snap/teams-for-linux/671/gnome-platform/usr/lib/x86_64-linux-gnu/dri)
libGL error: failed to load driver: iris
libGL error: MESA-LOADER: failed to open swrast (search paths /snap/teams-for-linux/671/gnome-platform/usr/lib/x86_64-linux-gnu/dri)
libGL error: failed to load driver: swrast
[2563670:0926/111245.476699:ERROR:angle_platform_impl.cc(44)] Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2563670:0926/111245.476825:ERROR:gl_display.cc(515)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.
[2563670:0926/111245.476843:ERROR:gl_display.cc(786)] eglInitialize OpenGL failed with error EGL_NOT_INITIALIZED, trying next display type
[2563670:0926/111245.520139:ERROR:angle_platform_impl.cc(44)] Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2563670:0926/111245.520298:ERROR:gl_display.cc(515)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.
[2563670:0926/111245.520339:ERROR:gl_display.cc(786)] eglInitialize OpenGLES failed with error EGL_NOT_INITIALIZED
[2563670:0926/111245.520369:ERROR:gl_display.cc(820)] Initialization of all EGL display types failed.
[2563670:0926/111245.520401:ERROR:gl_ozone_egl.cc(26)] GLDisplayEGL::Initialize failed.
[2563670:0926/111245.524273:ERROR:angle_platform_impl.cc(44)] Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2563670:0926/111245.524404:ERROR:gl_display.cc(515)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.
[2563670:0926/111245.524500:ERROR:gl_display.cc(786)] eglInitialize OpenGL failed with error EGL_NOT_INITIALIZED, trying next display type
[2563670:0926/111245.543435:ERROR:angle_platform_impl.cc(44)] Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
ERR: Display.cpp:1086 (initialize): ANGLE Display::initialize error 12289: Could not create a backing OpenGL context.
[2563670:0926/111245.543559:ERROR:gl_display.cc(515)] EGL Driver message (Critical) eglInitialize: Could not create a backing OpenGL context.
[2563670:0926/111245.543594:ERROR:gl_display.cc(786)] eglInitialize OpenGLES failed with error EGL_NOT_INITIALIZED
[2563670:0926/111245.543624:ERROR:gl_display.cc(820)] Initialization of all EGL display types failed.
[2563670:0926/111245.543651:ERROR:gl_ozone_egl.cc(26)] GLDisplayEGL::Initialize failed.
[2563670:0926/111245.551340:ERROR:viz_main_impl.cc(198)] Exiting GPU process due to errors during initialization
11:12:45.561 › Network test successful with method https
MESA-LOADER: failed to open iris (search paths /snap/teams-for-linux/671/gnome-platform/usr/lib/x86_64-linux-gnu/dri)
failed to load driver: iris
MESA-LOADER: failed to open kms_swrast (search paths /snap/teams-for-linux/671/gnome-platform/usr/lib/x86_64-linux-gnu/dri)
failed to load driver: kms_swrast
MESA-LOADER: failed to open swrast (search paths /snap/teams-for-linux/671/gnome-platform/usr/lib/x86_64-linux-gnu/dri)
failed to load swrast driver
[2563658:0926/111245.650917:ERROR:command_buffer_proxy_impl.cc(131)] ContextResult::kTransientFailure: Failed to send GpuControl.CreateCommandBuffer.
11:12:45.823 › GetSystemIdleState => IdleTimeout: 300s, IdleTimeoutPollInterval: 10s, ActiveCheckPollInterval: 2s, IdleTime: 0s, IdleState: 'active'
[2563551:0926/111245.825895:ERROR:object_proxy.cc(576)] Failed to call method: org.freedesktop.ScreenSaver.GetActive: object_path= /org/freedesktop/ScreenSaver: org.freedesktop.DBus.Error.NotSupported: This method is not part of the idle inhibition specification: https://specifications.freedesktop.org/idle-inhibit-spec/latest/
[2563551:0926/111245.999662:ERROR:CONSOLE(1)] "Request Autofill.enable failed. {"code":-32601,"message":"'Autofill.enable' wasn't found"}", source: devtools://devtools/bundled/core/protocol_client/protocol_client.js (1)
11:12:46.660 › did-frame-finish-load {} true
11:12:46.661 › did-finish-load
11:12:47.188 › did-frame-finish-load {} false
11:12:47.369 › assignOnDidFailLoadEventHandler : {} - -3 - 
11:12:47.525 › GetSystemIdleState => IdleTimeout: 300s, IdleTimeoutPollInterval: 10s, ActiveCheckPollInterval: 2s, IdleTime: 0s, IdleState: 'active'
11:12:47.572 › did-frame-finish-load {} true
11:12:47.573 › did-finish-load
[2563551:0926/111247.764836:ERROR:CONSOLE(1)] "Request Autofill.enable failed. {"code":-32601,"message":"'Autofill.enable' wasn't found"}", source: devtools://devtools/bundled/core/protocol_client/protocol_client.js (1)
11:12:47.768 › did-frame-finish-load {} false
^C11:12:55.287 › before-quit
11:12:55.288 › window close
11:12:55.294 › window closed
11:12:55.295 › will-quit
11:12:55.295 › quit

IMPORTANT: Ensure that you mask any sensitive information before posting the output.

Additional context Add any other context about the problem here.

ak2766 commented 1 month ago

Interestingly, the error below is only present when running TFL as: teams-for-linux --appLogLevels error,warn,info,debug but NOT when running it as: teams-for-linux --webDebug --logConfig='{}':

update.go:85: cannot change mount namespace according to change mount (/var/lib/snapd/hostfs/boot /boot none bind,ro 0 0): permission denied

Could it be that there's a missing connection that is now required on Ubuntu 24.04?

But seeing that it is in reference to /boot, maybe it can be ignore?

ak2766 commented 1 month ago

I found the following ticket: #183

From there, it seems to suggest that what I'm reporting as a bug in actually correct behaviour. Does that mean that whenever a new version comes out I need to remember to copy the config file to the new directory?

🤔 - but how is it that on Ubuntu 22.04 it was working as I pose in the bug report?

IsmaelMartinez commented 1 month ago

Hi @ak2766,

I am no expert on snap but that sounds like a pain to need to move the config file each time you run the app.

I am not sure if we can add something to the electron-builder, or if there is way in snap to configure a fix path.

Another option is to check if you can just specify that path by doing --config. We use yargs and their docs seem to indicate that might be an option

With regards the appLogLevels, that has been replaced with the logConfig.

I can see a few GPU errors but I assume you are running this in a VM, otherwise you might be better running the app with --disableGpu.

ak2766 commented 1 month ago

@IsmaelMartinez - thanks for your time.

I am no expert on snap but that sounds like a pain to need to move the config file each time you run the app.

Not each time I run the app, but whenever the snap revision changes.

Another option is to check if you can just specify that path by doing --config.

I tried using --config and many others to no avail.

I can see a few GPU errors but I assume you are running this in a VM, otherwise you might be better running the app with --disableGpu.

Nope - this is not a VM - it's my daily driver laptop. Ubuntu 24.04 has been the worst LTS released by Canonical in the history of Ubuntu! I'm waiting until 24.04.2 comes out to see if they've resolved many of the issues experienced so far by myriads of people. If not, it's back to 22.04.

I'll close this ticket for now but will update once I go back to 22.04 (I have no faith the bugs in 24.04 will be resolved). Hopefully, my recollection is correct that TFL honored the config in ~/.config/teams-for-linux in 22.04.

IsmaelMartinez commented 1 month ago

I think snap uses the other config folder (the one with the snap version) but, again, I am no expert.