Bug 503904 - kde-open doesn't handle x-scheme handlers correctly on URLs that include '-'
Summary: kde-open doesn't handle x-scheme handlers correctly on URLs that include '-'
Status: CONFIRMED
Alias: None
Product: frameworks-kio
Classification: Frameworks and Libraries
Component: general (other bugs)
Version First Reported In: 6.13.0
Platform: Fedora RPMs Linux
: NOR normal
Target Milestone: ---
Assignee: KIO Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-05-08 02:28 UTC by Luan Vitor Simião Oliveira
Modified: 2025-05-08 18:00 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments
discord desktop file with scheme handler support (369 bytes, application/x-desktop)
2025-05-08 02:28 UTC, Luan Vitor Simião Oliveira
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Luan Vitor Simião Oliveira 2025-05-08 02:28:45 UTC
Created attachment 181051 [details]
discord desktop file with scheme handler support

SUMMARY
if an app registers and x-scheme-handler mime type on their desktop file, and the urls for that app only include '-' on the hostname section, the handler will be ignored and the default web browser will be used instead.
discord is an example of this behavior, although they don't support it by default on Linux

STEPS TO REPRODUCE
1. put the attached file in $XDG_DATA_HOME/applications (might have to edit the exec to point to your discord install location)
2. make sure xdg-mime query default x-scheme-handler/discord returns discord.desktop
3. run kde-open "discord://-/settings/account"

OBSERVED RESULT
the url will be opened on the default web browser

EXPECTED RESULT
the discord app is opened on the settings page

SOFTWARE/OS VERSIONS

Operating System: Fedora Linux 42
KDE Plasma Version: 6.3.4
KDE Frameworks Version: 6.13.0
Qt Version: 6.9.0
Kernel Version: 6.14.5-300.fc42.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 16 × AMD Ryzen 7 9800X3D 8-Core Processor
Memory: 30.5 GiB of RAM
Graphics Processor 1: NVIDIA GeForce RTX 4070 Ti SUPER
Graphics Processor 2: AMD Radeon Graphics
Manufacturer: ASUS

ADDITIONAL INFORMATION
gio open "discord://-/settings/account"
is able to correctly invoke discord on the settings page for me