Bug 501359

Summary: When opening a new PDF file with Okular while an existing PDF file is being auto-reloaded, the existing file will be replaced
Product: [Applications] okular Reporter: Huanyu Liu <1293660441>
Component: generalAssignee: Okular developers <okular-devel>
Status: REPORTED ---    
Severity: normal    
Priority: NOR    
Version First Reported In: 24.12.3   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: A LaTeX source file with intentional error to create a long-standing auto-reload state

Description Huanyu Liu 2025-03-11 14:42:39 UTC
Created attachment 179306 [details]
A LaTeX source file with intentional error to create a long-standing auto-reload state

SUMMARY
If you open a new PDF file with Okular, while an existing PDF file is being auto-reloaded, then the new file will replace the existing one, instead of being opened in a new window.

STEPS TO REPRODUCE
0. Make sure you have a working TeX distribution, download the sample LaTeX source file, and prepare another arbitrary PDF file
1. Compile the source with `pdflatex error.tex`, and you will get an intentional error
2. Press Enter, so the compilation process will go ahead
3. Open the generated "error.pdf" file with Okular
4. Compile the source again; do not press enter this time, so the compilation process will get stuck
5. Now the "error.pdf" file is in an auto-reload state
6. Open the new PDF file with Okular

OBSERVED RESULT
The new file replaces "error.pdf"

EXPECTED RESULT
The new file should be opened in a new window

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 6.3.2
KDE Frameworks Version: 6.11.0
Qt Version: 6.8.2
Kernel Version: 6.13.6-arch1-1 (64-bit)
Graphics Platform: Wayland

ADDITIONAL INFORMATION
You can use other techniques to create a long-standing auto-reload state instead of compiling a LaTeX source.