Bug 513684 - Konsole path recognition error when it is `/home/${USER}foo`
Summary: Konsole path recognition error when it is `/home/${USER}foo`
Status: ASSIGNED
Alias: None
Product: konsole
Classification: Applications
Component: tabbar (other bugs)
Version First Reported In: 25.12.0
Platform: Arch Linux Linux
: NOR minor
Target Milestone: ---
Assignee: Konsole Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-12-21 23:34 UTC by XiJet
Modified: 2025-12-25 11:11 UTC (History)
1 user (show)

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


Attachments
Replay for 513684#c1 (484.37 KB, video/mp4)
2025-12-24 20:09 UTC, XiJet
Details

Note You need to log in before you can comment on or make changes to this bug.
Description XiJet 2025-12-21 23:34:06 UTC
## SUMMARY
Konsole incorrectly parses the path string passed via the OSC 7 escape sequence, leading to an incorrect terminal window/tab title (expected username+suffix, got `~a`).

## STEPS TO REPRODUCE
1. `echo -e "\033]7;file:///home/$(whoami)a\033\\"`

## OBSERVED RESULT
Tab/Window's title become `~a`

## EXPECTED RESULT
Show the real dir name `fooa` in title. (If $USER is "foo")

## SOFTWARE/OS VERSIONS
`kinfo`:  
```plaintext
Operating System: Arch Linux 
KDE Plasma Version: 6.5.4
KDE Frameworks Version: 6.21.0
Qt Version: 6.10.1
Kernel Version: 6.18.1-zen1-2-zen (64-bit)
Graphics Platform: Wayland
Processors: 22 × Intel® Core™ Ultra 7 155H
Memory: 32 GiB of RAM (30.5 GiB usable)
Graphics Processor: Intel® Arc
```

## ADDITIONAL INFORMATION
Initially, I reported this in the fish-shell repository's issues: https://github.com/fish-shell/fish-shell/issues/12195  
However, it is not fish-shell's wrong.

This problem does not affect Dolphin.
Comment 1 elijaharagonmorgan 2025-12-24 18:17:54 UTC
tried on same version
no issue

needs video proof of concept
Comment 2 XiJet 2025-12-24 19:53:49 UTC
(In reply to elijaharagonmorgan from comment #1)
> tried on same version
> no issue
> 
> needs video proof of concept

(I casually picked a website to upload the reproduction video. If you prefer not to visit non-OSS websites, sorry for the inconvenience.)
https://files.catbox.moe/bd03wr.mp4
Comment 3 XiJet 2025-12-24 20:09:52 UTC
Created attachment 187952 [details]
Replay for 513684#c1

Sorry, I didn't notice that this webpages has a file update function.
Comment 4 elijaharagonmorgan 2025-12-24 20:20:49 UTC
Pls explain exactly the steps you perform from starting your computer.
Comment 5 Bug Janitor Service 2025-12-25 11:11:21 UTC
A possibly relevant merge request was started @ https://invent.kde.org/utilities/konsole/-/merge_requests/1159