Closed Bug 1914742 Opened 6 months ago Closed 3 months ago

[KDE] Gmail - File drag and drop broke on KDE/Linux , 126.0.2->129.0.2

Categories

(Core :: Widget: Gtk, defect, P2)

Firefox 129
Desktop
Linux
defect

Tracking

()

RESOLVED FIXED
135 Branch
Tracking Status
firefox-esr128 --- fixed
firefox133 --- wontfix
firefox134 --- fixed
firefox135 --- fixed

People

(Reporter: metal450, Assigned: stransky)

References

(Blocks 1 open bug)

Details

Attachments

(5 files)

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

Steps to reproduce:

  1. On KDE, open Firefox 126.0.2
  2. Go to GMail
  3. Compose a new e-mail
  4. Drag a file from the KDE desktop or Dolphin to the e-mail. It will upload & attach the file, as expected (and as in all prior versions of Firefox)
  5. Update to Firefox 129.0.2
  6. Repeat the same. It no longer attaches the file - instead, it just inserts the text of the path of the file (i.e. "file:///home/username/Desktop/somefile.jpg)

The same is true of other sites - i.e. can no longer drag files into Facebook chat conversations, etc.

Actual results:

Described in steps

Expected results:

Described in steps

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
Blocks: linuxdad
OS: Unspecified → Linux
Hardware: Unspecified → Desktop

Can you use mozregression tool to find broken commit?
https://fedoraproject.org/wiki/How_to_debug_Firefox_problems#Use_Mozregression_tool
Thanks!

Flags: needinfo?(metal450)

5:56.50 INFO: Narrowed integration regression window from [aba3d5bd, f061d37c] (3 builds) to [068001f3, f061d37c] (2 builds) (~1 steps left)
5:56.50 INFO: No more integration revisions, bisection finished.
5:56.50 INFO: Last good revision: 068001f3181654a5663191fc437ab74f19ab3f7f
5:56.50 INFO: First bad revision: f061d37ca7aea8d05d976908e376e649257f2151
5:56.50 INFO: Pushlog:
https://hg.mozilla.org/releases/mozilla-release/pushloghtml?fromchange=068001f3181654a5663191fc437ab74f19ab3f7f&tochange=f061d37ca7aea8d05d976908e376e649257f2151

Flags: needinfo?(metal450)

Looks like there are lot of D&D changes in that range.
Please attach your about:support page.
Thanks.

Summary: File drag and drop broke on KDE/Linux , 126.0.2->129.0.2 → [KDE] File drag and drop broke on KDE/Linux , 126.0.2->129.0.2
Flags: needinfo?(metal450)

Quite a bit on that page - are there any particular sections you're interested in? I prefer to review any logs/content like that for privacy reasons, would be quicker to send just the relevant sections if possible.

Flags: needinfo?(metal450)
Flags: needinfo?(metal450)

Attached. First I show the broken behavior in the current version of Firefox; then I show the correct behavior in Brave (which reflects how Firefox worked before the broken update).

Flags: needinfo?(metal450)

It works for me in Gnome/Wayland/Firefox 130.0. May be KDE specific.

Please run Firefox on terminal with MOZ_LOG="WidgetDrag:5" env variable, reproduce the issue and attach the log here. Run for instance:

MOZ_LOG="WidgetDrag:5" firefox > log.txt 2>&1

and attach log.txt file.
Thanks.

Flags: needinfo?(metal450)
Priority: -- → P2
Attached file log.txt

I'm also using x11, not Wayland.

Attached

Flags: needinfo?(metal450)

Still broken on 130.0.1

Still facing this on firefox 133.0. Using Kubuntu 22.04 with X11 desktop backend.

Duplicate of this bug: 1934771

May be dupe of Bug 1917854.

See Also: → 1917854

This may be the bug:

[Parent 154475: Main Thread]: D/WidgetDrag nsWindow::OnDragDataReceived
[Parent 154475: Main Thread]: D/WidgetDrag [D 2] nsDragService::TargetDataReceived(7fc5d06a69e0) MIME application/vnd.portal.filetransfer mWaitingForDragDataRequests 0
[Parent 154475: Main Thread]: D/WidgetDrag [D 2] TargetDataReceived(): plain data, MIME application/vnd.portal.filetransfer len = 19
[Parent 154475: Main Thread]: D/WidgetDrag [D 1] application/vnd.portal.filetransfer received
[Parent 154475: Main Thread]: D/WidgetDrag DragData::Export() MIME application/vnd.portal.filetransfer index 0
[Parent 154475, Main Thread] WARNING: g_strv_length: assertion 'str_array != NULL' failed: 'glib warning', file /build/firefox-NUtzHF/firefox-129.0.2+build1/toolkit/xre/nsSigHandlers.cpp:187

(firefox:154475): GLib-CRITICAL **: 16:12:46.657: g_strv_length: assertion 'str_array != NULL' failed

Summary: [KDE] File drag and drop broke on KDE/Linux , 126.0.2->129.0.2 → [KDE] Gmail - File drag and drop broke on KDE/Linux , 126.0.2->129.0.2
Flags: needinfo?(stransky)
See Also: → 1913643

Can you please re-test with latest nightly?
https://fedoraproject.org/wiki/How_to_debug_Firefox_problems#Testing_Mozilla_Nightly_binaries
I can't reproduce it with Fedora 41 / KDE / X11.
Thanks.

Flags: needinfo?(stransky) → needinfo?(metal450)

Still broken in 135.0a1 (2024-12-04)

Flags: needinfo?(metal450)

Thanks for testing. I'd need fresh logs for it.

Please run Firefox on terminal with MOZ_LOG="WidgetDrag:5" env variable, reproduce the issue and attach the log here. Run for instance:
MOZ_LOG="WidgetDrag:5" firefox > log.txt 2>&1
and attach log.txt file.

Thanks.

Flags: needinfo?(metal450)
Attached file drag-log.txt
Flags: needinfo?(metal450)

Attached

Thanks. Please attach about:support page.

I suspect Bug 1908196 may fix this one, let's re-test when it lands.

According to the log you use old Gtk3 version where gtk_targets_include_uri() doesn't include portal MIME types.

Assignee: nobody → stransky
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Pushed by stransky@redhat.com: https://hg.mozilla.org/integration/autoland/rev/3cfce0e75164 [Linux] Don't use gtk_targets_include_uri() to get URI MIME types as it depends on Gtk3 version r=emilio

(In reply to Martin Stránský [:stransky] (ni? me) from comment #21)

Thanks. Please attach about:support page.

I suspect Bug 1908196 may fix this one, let's re-test when it lands.

Easier to just re-test when it lands, lmk when ready + I will

Status: ASSIGNED → RESOLVED
Closed: 3 months ago
Resolution: --- → FIXED
Target Milestone: --- → 135 Branch

Landed so please test.
Thanks.

confirmed, fixed at last.

Any idea how long these nightlies end up taking to make it into production?

I'll do backport for Beta.

Flags: needinfo?(stransky)
Flags: needinfo?(stransky)
Attachment #9442385 - Flags: approval-mozilla-beta?

Comment on attachment 9442385 [details]
Bug 1914742 [Linux] Don't use gtk_targets_include_uri() to check URI types for 134.0 r?emilio

Beta/Release Uplift Approval Request

  • User impact if declined/Reason for urgency: Firefox fails to D&D files or file link if running on old Gtk3 version where gtk_targets_include_uri() doesn't support portal filetypes.
  • Is this code covered by automated tests?: No
  • Has the fix been verified in Nightly?: Yes
  • Needs manual test from QE?: No
  • If yes, steps to reproduce:
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): We only replace Gtk3 function with our correct check.
  • String changes made/needed:
  • Is Android affected?: Yes
Attachment #9442385 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

Do we want this on ESR128 also?

Flags: needinfo?(stransky)

(In reply to Ryan VanderMeulen [:RyanVM] from comment #33)

Do we want this on ESR128 also?

Yes, I think so.

Flags: needinfo?(stransky)

Comment on attachment 9442385 [details]
Bug 1914742 [Linux] Don't use gtk_targets_include_uri() to check URI types for 134.0 r?emilio

ESR Uplift Approval Request

  • If this is not a sec:{high,crit} bug, please state case for ESR consideration: Firefox fails to D&D files or file link if running on old Gtk3 version where gtk_targets_include_uri() doesn't support portal filetypes.
  • User impact if declined:
  • Fix Landed on Version:
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): We only replace Gtk3 function with our correct check.
Attachment #9442385 - Flags: approval-mozilla-esr128?

Comment on attachment 9442385 [details]
Bug 1914742 [Linux] Don't use gtk_targets_include_uri() to check URI types for 134.0 r?emilio

Approved for 128.6esr.

Attachment #9442385 - Flags: approval-mozilla-esr128? → approval-mozilla-esr128+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: