Closed Bug 1766256 Opened 3 years ago Closed 3 years ago

firefox crashes when opening file upload window

Categories

(Core :: Widget: Gtk, defect)

Firefox 99
defect

Tracking

()

RESOLVED INVALID

People

(Reporter: mail_bybs, Unassigned)

References

(Blocks 1 open bug)

Details

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:99.0) Gecko/20100101 Firefox/99.0

Steps to reproduce:

firefox snap for ubuntu 22.04 lts v. 99.0.1 x64.

steps:

  1. open browser
  2. open any site, like "jira"
  3. click on drop-zone or file input field
  4. crash

Actual results:

Browser crashed with error:

Gtk:ERROR:../src/gtk/gtkiconhelper.c:494:ensure_surface_for_gicon: assertion failed (error == NULL): Failed to load /snap/firefox/1232/data-dir/icons/Adwaita/16x16/status/image-missing.png: Нераспознанный формат файла изображения (gdk-pixbuf-error-quark, 3)

I would attach the full log, but the upload form doesn't work :D

Expected results:

Should have opened a file upload window and after selecting the file should be loaded correctly

The Bugbug bot thinks this bug should belong to the 'Core::Widget: Gtk' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: Untriaged → Widget: Gtk
Product: Firefox → Core

Does this happen on a non-snap build like https://nightly.mozilla.org or so?

Flags: needinfo?(mail_bybs)

(In reply to Emilio Cobos Álvarez (:emilio) from comment #2)

Does this happen on a non-snap build like https://nightly.mozilla.org or so?

No. I checked "firefox-101.0a1.ru.linux-x86_64" but the error didn't happen again.

I think that the error is not related to the specific assembly of the browser, but is related to the snap package. Because the error above says that the file format was not determined. But the file is not in the system at all

ave404@ave404-desktop:~$ file /snap/firefox/1232/data-dir/icons/Adwaita/16x16/status/image-missing.png
/snap/firefox/1232/data-dir/icons/Adwaita/16x16/status/image-missing.png: cannot open `/snap/firefox/1232/data-dir/icons/Adwaita/16x16/status/image-missing.png' (No such file or directory)
Flags: needinfo?(mail_bybs)

Can you please share the output of snap list and snap connections firefox ?

I suspect the gtk-common-themes snap might not be installed, or disconnected from the corresponding firefox plug.

Flags: needinfo?(mail_bybs)
ave404@ave404-desktop:~$ snap list
Название           Версия           Правка  Канал          Издатель    Примечание
bare               1.0              5       latest/stable  canonical✓  base
chromium           100.0.4896.127   1967    latest/stable  canonical✓  -
core20             20220318         1405    latest/stable  canonical✓  base
firefox            99.0.1-1         1232    latest/stable  mozilla✓    -
gnome-3-38-2004    0+git.1f9014a    99      latest/stable  canonical✓  -
gtk-common-themes  0.1-59-g7bca6ae  1519    latest/stable  canonical✓  -
snapd              2.55.3           15534   latest/stable  canonical✓  snapd
ave404@ave404-desktop:~$ snap connections firefox
Interface                 Plug                            Slot                             Notes
audio-playback            firefox:audio-playback          :audio-playback                  -
audio-record              firefox:audio-record            :audio-record                    -
avahi-observe             firefox:avahi-observe           :avahi-observe                   -
browser-support           firefox:browser-sandbox         :browser-support                 -
camera                    firefox:camera                  :camera                          -
content[gnome-3-38-2004]  firefox:gnome-3-38-2004         gnome-3-38-2004:gnome-3-38-2004  -
content[gtk-3-themes]     firefox:gtk-3-themes            gtk-common-themes:gtk-3-themes   -
content[icon-themes]      firefox:icon-themes             gtk-common-themes:icon-themes    -
content[sound-themes]     firefox:sound-themes            gtk-common-themes:sound-themes   -
cups-control              firefox:cups-control            :cups-control                    -
dbus                      -                               firefox:dbus-daemon              -
desktop                   firefox:desktop                 :desktop                         -
desktop-legacy            firefox:desktop-legacy          :desktop-legacy                  -
gsettings                 firefox:gsettings               :gsettings                       -
hardware-observe          firefox:hardware-observe        :hardware-observe                -
home                      firefox:home                    :home                            -
joystick                  firefox:joystick                :joystick                        -
mpris                     -                               firefox:mpris                    -
network                   firefox:network                 :network                         -
network-observe           firefox:network-observe         -                                -
opengl                    firefox:opengl                  :opengl                          -
personal-files            firefox:dot-mozilla-firefox     :personal-files                  -
removable-media           firefox:removable-media         :removable-media                 -
screen-inhibit-control    firefox:screen-inhibit-control  :screen-inhibit-control          -
system-files              firefox:etc-firefox-policies    :system-files                    -
system-packages-doc       firefox:system-packages-doc     :system-packages-doc             -
u2f-devices               firefox:u2f-devices             :u2f-devices                     -
unity7                    firefox:unity7                  :unity7                          -
upower-observe            firefox:upower-observe          :upower-observe                  -
wayland                   firefox:wayland                 :wayland                         -
x11                       firefox:x11                     :x11                             - 

Perhaps it will be important to understand

In the morning I have version 21.10 and snap was not installed. after that i upgraded ubuntu to 22.04. snap and firefox were installed during the update process

So I can assure you that snap dependencies and packages were not manually affected

P.S. I use a translator from Russian to English and some things may be inaccurate

Flags: needinfo?(mail_bybs)

Can you close firefox, execute the following command, then run it again, and see if the problem is gone?

rm -rf ~/snap/firefox/common/.cache
Flags: needinfo?(mail_bybs)

(In reply to Olivier Tilloy from comment #6)

Can you close firefox, execute the following command, then run it again, and see if the problem is gone?

rm -rf ~/snap/firefox/common/.cache

Now when I try to open the file upload window, nothing happens

ave404@ave404-desktop:~$ rm -rf ~/snap/firefox/common/.cache
ave404@ave404-desktop:~$ firefox 
Gtk-Message: 10:27:47.030: Failed to load module "canberra-gtk-module"
Gtk-Message: 10:27:47.032: Failed to load module "canberra-gtk-module"
ATTENTION: default value of option mesa_glthread overridden by environment.
ATTENTION: default value of option mesa_glthread overridden by environment.
[2022-04-28T07:27:56Z ERROR mp4parse] Found 2 nul bytes in "\u{0}\u{0}"
[2022-04-28T07:27:56Z ERROR mp4parse] Found 2 nul bytes in "\u{0}\u{0}"
[2022-04-28T07:27:56Z ERROR mp4parse] Found 2 nul bytes in "\u{0}\u{0}"
[2022-04-28T07:27:56Z ERROR mp4parse] Found 2 nul bytes in "\u{0}\u{0}"

(firefox:7549): Gtk-WARNING **: 10:28:00.353: Can't open portal file chooser: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.portal.Desktop was not provided by any .service files

(firefox:7549): Gtk-WARNING **: 10:28:04.003: Can't open portal file chooser: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.portal.Desktop was not provided by any .service files

(firefox:7549): Gtk-WARNING **: 10:28:07.425: Can't open portal file chooser: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.portal.Desktop was not provided by any .service files

(firefox:7549): Gtk-WARNING **: 10:28:16.655: Can't open portal file chooser: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.portal.Desktop was not provided by any .service files

###!!! [Parent][PImageBridgeParent] Error: RunMessage(msgname=PImageBridge::Msg_WillClose) Channel closing: too late to send/recv, messages will be lost

ave404@ave404-desktop:~$ 
Flags: needinfo?(mail_bybs)

It looks like you're missing the portal implementation. Can you try:

sudo apt install xdg-desktop-portal-gnome
Flags: needinfo?(mail_bybs)

(In reply to Olivier Tilloy from comment #8)

It looks like you're missing the portal implementation. Can you try:

sudo apt install xdg-desktop-portal-gnome

After installing the package everything worked, thanks. It is strange that when updating the system and installing firefox, the dependency was not installed.

Whereas, for example, in chromium everything works without this package

Flags: needinfo?(mail_bybs)

Agreed, that package should have been installed automatically indeed. I'm looking into that on the Ubuntu packaging side of things.

Status: UNCONFIRMED → RESOLVED
Closed: 3 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.