Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open in folder broken on Linux #43082

Closed
5 of 6 tasks
MANICX100 opened this issue Jan 1, 2025 · 11 comments
Closed
5 of 6 tasks

Open in folder broken on Linux #43082

MANICX100 opened this issue Jan 1, 2025 · 11 comments
Labels
OS/Desktop OS/Linux priority/P3 The next thing for us to work on. It'll ride the trains.

Comments

@MANICX100
Copy link

Description

Xdg-mime / xdg-open is set correctly but it doesnt matter what file manager i set or use the show in folder option does nothing. Tried export log via terminal but no useful info.

Deb version on FunOS based on Ubuntu Noble tested on both google-chrome, brave stable and brave-nightly.

Steps to reproduce

  1. Download a file
  2. Press show in folder
  3. Nothing happens

Actual result

Nothing

Expected result

Folder opens in correct directory

Reproduces how often

Easily reproduced

Brave version (brave://version info)

Nightly
Brave 1.75.139 Chromium: 132.0.6834.57 (Official Build) nightly (64-bit)
Revision 824a4385d099e741400ccd850d3309105a1f2c5e
OS Linux
JavaScript V8 13.2.152.23
User Agent Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/132.0.0.0 Safari/537.36
Command Line /opt/brave.com/brave-nightly/brave --disable-domain-reliability --enable-dom-distiller --enable-distillability-service --origin-trial-public-key=bYUKPJoPnCxeNvu72j4EmPuK7tr1PAC7SHh8ld9Mw3E=,fMS4mpO6buLQ/QMd+zJmxzty/VQ6B1EUZqoCU04zoRU= --lso-url=https://no-thanks.invalid --variations-server-url=https://variations.brave.com/seed --variations-insecure-server-url=https://variations.brave.com/seed --flag-switches-begin --flag-switches-end --component-updater=url-source=https://go-updater.brave.com/extensions
Executable Path /opt/brave.com/brave-nightly/brave
Profile Path /home/dkendall/.config/BraveSoftware/Brave-Browser-Nightly/Default
Command-line Variations IC0tZm9yY2UtZmllbGR0cmlhbHM9IipBbGxvd0NlcnRhaW5DbGllbnRIaW50...
Active Variations main@a57acceeac76f9e1e94a52c2dc8e025872bf853c
AllowCertainClientHintsStudy:Enabled
BraveAIChatDefaultModelStudy:DefaultLlama
BraveAdblockExperimentalListDefaultStudy:Enabled
BraveAdblockMobileNotificationsListDefault:Enabled
BraveAdsAdEventStudy:Enabled
BraveAdsConversionsStudy:Enabled
BraveAdsExclusionRulesStudy:Enabled
BraveAdsNewTabPageAdsStudy:Enabled
BraveAdsRedeemRewardConfirmationStudy:Enabled
BraveAdsSiteVisitStudy:Enabled
BraveAdsTextClassificationPageProbabilitiesStudy:Enabled
BraveAggressiveModeRetirementExperiment:Disabled
BraveAutoTranslateStudy:AutoTranslateDisabled
BraveDebounceStudy:Enabled
BraveFallbackDoHStudy:Enabled
BraveForgetFirstPartyStorage:Enabled
BraveGoogleSignInPermissionStudy:Enabled
BraveHorizontalTabsUpdateEnabledStudy:Enabled
BraveLocalhostAccessPermissionStudy:Enabled
BraveP3AConstellationEnabled:Enabled
BraveP3AJSONOtherDeprecation:Enabled
BraveP3ANebulaNightlyBeta:Enabled
BraveP3ATypicalJSONDeprecationEnabled:Enabled
BraveRequestOTRTabRolloutStudy:Enabled
BraveRewardsAllowSelfCustodyProvidersStudy:Enabled
BraveRewardsWebUiPanelStudy:Enabled
BraveScreenFingerprintingBlockerStudy:Enabled
BraveSearchAdStudy:Enabled
BraveSearchPromotionBannerStudy:banner_type_D
BraveWalletAnkrBalancesEnabled:Default
BraveWebViewRoundedCornersStudy:Enabled
BraveWebcompatExceptionsServiceStudy:Enabled
ClampPlatformVersionClientHint:Disabled
CookieListDefaultStudy:Enabled
CosmeticFilteringChildFramesStudy:Enabled
Default1pBlockingStudy:Disabled
DefaultBraveCommandsStudy:Enabled
DefaultBraveOmniboxMoreHistoryStudy:Enabled
DefaultPlaylistStudy:Enabled
DisableReduceLanguage:Enabled
EphemeralStorageStudy:Enabled
ExtensionsManifestV2Study:Enabled
HangWatcher:HangWatcherEnableDumps
PartitionedCookies:Enabled
SeedFileTrial:Control_V3
UndecryptablePasswords:Enabled
UserActivityStudy:Triggers

Channel information

  • release (stable)
  • beta
  • nightly

Reproducibility

  • with Brave Shields disabled
  • with Brave Rewards disabled
  • in the latest version of Chrome

Miscellaneous information

No flags enabled

@MANICX100
Copy link
Author

Stable:

Brave 1.73.104 Chromium: 131.0.6778.204 (Official Build) (64-bit)
Revision 215b794a7c1f3e28151d0f7712e32c71be48775c
OS Linux
JavaScript V8 13.1.201.19
User Agent Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36
Command Line /opt/brave.com/brave/brave --disable-domain-reliability --enable-dom-distiller --enable-distillability-service --origin-trial-public-key=bYUKPJoPnCxeNvu72j4EmPuK7tr1PAC7SHh8ld9Mw3E=,fMS4mpO6buLQ/QMd+zJmxzty/VQ6B1EUZqoCU04zoRU= --lso-url=https://no-thanks.invalid --sync-url=https://sync-v2.brave.com/v2 --variations-server-url=https://variations.brave.com/seed --variations-insecure-server-url=https://variations.brave.com/seed --flag-switches-begin --flag-switches-end --component-updater=url-source=https://go-updater.brave.com/extensions
Executable Path /opt/brave.com/brave/brave
Profile Path /home/dkendall/.config/BraveSoftware/Brave-Browser/Default

@rebron rebron added the OS/Linux label Jan 7, 2025
@rebron rebron added this to General Jan 7, 2025
@rebron rebron added the priority/P3 The next thing for us to work on. It'll ride the trains. label Jan 7, 2025
@fmarier
Copy link
Member

fmarier commented Jan 7, 2025

What happens if you run these on your machine?

xdg-open /home/francois/download/

That does work for me (nautilus + Pop!_OS 22.04, based on Ubuntu jammy), same as the open in folder option in brave://downloads/ in Brave Beta.

@MANICX100
Copy link
Author

What happens if you run these on your machine?

xdg-open /home/francois/download/

That does work for me (nautilus + Pop!_OS 22.04, based on Ubuntu jammy), same as the open in folder option in brave://downloads/ in Brave Beta.

xdg-open works perfectly. The directory francios naturally isnt on my system but if I make it, it works, all folders open correctly.

@fmarier
Copy link
Member

fmarier commented Jan 8, 2025

And this is the deb version not the Snap, right?

Any errors/warnings in the terminal if you start Brave from the command-line and then click "Show in folder"?

@MANICX100
Copy link
Author

And this is the deb version not the Snap, right?

Any errors/warnings in the terminal if you start Brave from the command-line and then click "Show in folder"?

No errors
Deb version
Running with verbose logging just produced lots of extension related messages
No change without extensions

@fmarier
Copy link
Member

fmarier commented Jan 8, 2025

And are you able to test in Chrome? Wondering whether it's something Brave-specific, or if it's a problem from upstream Chromium.

@bsclifton
Copy link
Member

bsclifton commented Jan 9, 2025

Definitely seems to be just shelling out to do xdg-open:
https://source.chromium.org/chromium/chromium/src/+/main:chrome/browser/platform_util_linux.cc;l=369-388;drc=ff9514b10048f37fbe27ec415ec2990b57d8cdc3

This has to be happening in Chrome / Chromium also

@MANICX100
Copy link
Author

And are you able to test in Chrome? Wondering whether it's something Brave-specific, or if it's a problem from upstream Chromium.

Ah so I have the same issue in chrome.

Does that mean this should be closed?

In case anyone is interested this is the distro i am running

@MANICX100
Copy link
Author

I fixed the issue.

So it wasn't a chromium issue at all. It turns out FunOS which I use uses a random DBus call and overrides xdg-mime. Firefox was configured with custom config so didnt see this issue.

Solution for future readers:

create /etc/dbus-1/session-local.conf

sudo $EDITOR /etc/dbus-1/session-local.conf

with the content:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE busconfig PUBLIC "-//freedesktop//DTD D-Bus Bus Configuration 1.0//EN"
 "http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">

<busconfig>
  <policy context="default">
    <!-- Block all usage of org.freedesktop.FileManager1 for opening files -->
    <deny send_interface="org.freedesktop.FileManager1" send_destination="org.freedesktop.FileManager1"/>
  </policy>
</busconfig>

Now reload dbus with:

dbus-send --session --print-reply --dest=org.freedesktop.DBus --type=method_call /org/freedesktop/DBus org.freedesktop.DBus.ReloadConfig

@github-project-automation github-project-automation bot moved this to Completed in General Jan 11, 2025
@fmarier
Copy link
Member

fmarier commented Jan 12, 2025

Interesting, so it's actually a FunOS bug then?

@MANICX100
Copy link
Author

Interesting, so it's actually a FunOS bug then?

Yep. I'm just happy to have fixed it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OS/Desktop OS/Linux priority/P3 The next thing for us to work on. It'll ride the trains.
Projects
Status: Completed
Development

No branches or pull requests

4 participants