Bug 506827

Summary: When launched with different DISPLAY or WAYLAND_DISPLAY than an existing process, should open a new instance
Product: [Applications] okular Reporter: Sergio <sergio.callegari>
Component: generalAssignee: Okular developers <okular-devel>
Status: REPORTED ---    
Severity: normal    
Priority: NOR    
Version First Reported In: 25.04.2   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Sergio 2025-07-09 21:53:50 UTC
SUMMARY

When okular is launched for a document and an existing instance is running, there is the option to open a new tab on the existing instance, rather than launching a new instance.

However, if okular is launched with different DISPLAY or WAYLAND_DISPLAY environment variables with respect to the existing instance, it seems logical that the user *needs* to open a new instance.

The problem is particularly evident when using waypipe. Because of this the reproduction case will be based on a waypipe scenario, involving two hosts, A and B

STEPS TO REPRODUCE
1. start a KDE session on B, login and open okular to display some document. Ensure that it is configured to open new files in tabs
2. start a session on A, connect to B with waypipe (e.g. waypipe ssh B)
3. from the waypipe session on A, open okular to display some document.

OBSERVED RESULT

A new tab opens on the okular instance running on B

EXPECTED RESULT

A new instance displayed on A via waypipe

SOFTWARE/OS VERSIONS

Operating System: Manjaro Linux 
KDE Plasma Version: 6.3.5
KDE Frameworks Version: 6.15.0
Qt Version: 6.9.1
Kernel Version: 6.15.3-1-MANJARO (64-bit)
Graphics Platform: Wayland

ADDITIONAL INFORMATION

N/A