8000 texstudio crashes when use internal view-pdf · Issue #4023 · texstudio-org/texstudio · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

texstudio crashes when use internal view-pdf #4023

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

Closed
Ame-sakura opened this issue Mar 15, 2025 · 31 comments
Closed

texstudio crashes when use internal view-pdf #4023

Ame-sakura opened this issue Mar 15, 2025 · 31 comments

Comments

@Ame-sakura
Copy link

Environment

  • TeXstudio: 4.8.6
  • Qt: 6.8.2
  • OS: Win10
  • TeX distribution: texlive

Actual behavior

After I build a .tex file, I want to view it in the internal pdf-viewer(F7), then texstudio crashes. But the PDFfile has no problem because I can view it by external PDF-reader, such as Acrobat. I think the building is successful, but the internal pdf-viewer has some wrong.
More information: If change the Render Backend of internal pdf-viewer from Splash to Arthur, then no crash, but the PDF in the viewer only show Chinese character, any number and letter disappear, see attachment

Image

. PDFfile is normal.
4.8.5version has the same problem.

How to reproduce

It only appear on my computer, I don't know how to reproduce.

@sunderme
Copy link
Member

Without a test case, there is nothing we can do.
Providing the pdf is the bare minimum.
If there are any special circumstances which make it crash, we need to know.

@Ame-sakura
Copy link
Author

没有测试用例,我们什么也做不了。 提供 pdf 是最低限度的要求。 如果有任何特殊情况导致它崩溃,我们需要知道。

I j 8000 ust did a lot of testing, the files used for the test are attached. The specific results are:
1.document.tex and test1.tex have the same content, their performence are seemed to be the same also: When using the internal pdf-viewer, the software crashes about half the time.
2.test0.tex: always crash when use internal pdf-viewer.
3.Open docement.tex(or test1.tex) and test0.tex meanwhile, if their is no crash when using the internal pdf-viewer for the former, then no crash for the latter. After using the internal pdf-viewer normally for the latter as the previous sentence said, close the view and open it again(F7), then crash.

test.zip

@Ame-sakura
Copy link
Author

没有测试用例,我们什么也做不了。 提供 pdf 是最低限度的要求。 如果有任何特殊情况导致它崩溃,我们需要知道。

I just did a lot of testing, the files used for the test are attached. The specific results are: 1.document.tex and test1.tex have the same content, their performence are seemed to be the same also: When using the internal pdf-viewer, the software crashes about half the time. 2.test0.tex: always crash when use internal pdf-viewer. 3.Open docement.tex(or test1.tex) and test0.tex meanwhile, if their is no crash when using the internal pdf-viewer for the former, then no crash for the latter. After using the internal pdf-viewer normally for the latter as the previous sentence said, close the view and open it again(F7), then crash.

test.zip

Add a sentence: test0.tex is created in 4.3.7version, test1.tex is created in 4.8.5version, and document.tex is 4.8.6version.
Hope these are useful

@Ame-sakura
Copy link
Author

!A very important message: In test0.tex, there are two [figure] environment next to each other. Delete one or both of them then no crash. document.tex is the same.

@Ame-sakura
Copy link
Author

!A very important message: In test0.tex, there are two [figure] environment next to each other. Delete one or both of them then no crash. document.tex is the same.

I think the crash depends on the number of pictures(or [figure] environment?): <=1, no crash; =2 carsh half the time; =3, almost crash every time, occasionally it won't crash.

@sunderme
Copy link
Member

I see the crash on windows (test1.pdf)
It crashes in poppler. I will check if it still crashes in a newer version of poppler, but poppler is migrating its infrastructure, so that may take a few days.

@HClO4
Copy link
HClO4 commented Mar 19, 2025

I have the same issue with one of my colleagues documents. As the document is rather large I did not find the exact part of the PDF that causes the crash.
When only the external viewer is used, everything works fine.

@sunderme
Copy link
Member

I am not seeing the crash any more on windows. No idea what changed.

@Ame-sakura
Copy link
Author

I am not seeing the crash any more on windows. No idea what changed.

The crash still appear on my desktop, and the phenomenon is as the same.

@sunderme
Copy link
8000
Member

general update.
it crashes also with poppler 25.03
It seems somehow to be a setup issue of the binaries. Starting texstudio from msys directly does not lead to a crash.

@gama20000
Copy link

Environment

TeXstudio: 4.8.6
Qt: 6.8.2
OS: Win10
TeX distribution: MiKTeX

This also happens to me. The weird part was the first crash happended when was trying to add a word to the dictionary, the it completely crashed. Had to remove lastsession information. Now the inbuilt pdf when i to try to oppen a pdf crashes... But the pdf oppens in external viewer.

@sunderme
Copy link
Member
sunderme commented Apr 4, 2025

Please provide the pdf which causes the crash.
It is just speculation that it is the same mechanism.

@mroman-ibs
Copy link

The same happens to me. I've added an example. It looks like too many pdf figures inside the main file cause the problem. External viewer (Acrobat) works without the errors.

test01.pdf

Environment: TeXstudio 4.8.6 (git 4.8.6), Qt 6.8.2, Win 11, TexLive 2025

@sunderme
Copy link
Member

I don't see the crash anymore.
Can you try 4.8.7beta2

@mroman-ibs
Copy link

It still crashes with 4.8.7beta2.

@sunderme
Copy link
Member

please send the backtrace

@mroman-ibs
Copy link

Can you provide some hints where the backtrace file resides or how to create it? I've checked c:\users\my_name\AppData\Local\Temp, but I've found nothing there.

@sunderme
Copy link
Member

that is where it should be.
Do you get a pop-up on the crash ? Asking you to kill the program ?

@mroman-ibs
Copy link

Yes, there was a message. I've got also the respective dmb file in CrashDumps.

@pkabal
Copy link
pkabal commented Apr 16, 2025

Same problem texstudio 4.86 crashes trying to open PDF viewer. It seems to be caused by stale files in Program Files/texstudio. These may refer to earlier versions of Qt.

  • Uninstall 4.86
  • Delete Program Files/texstudio folder
  • Reinstall 4.86

@sunderme
Copy link
Member
sunderme commented Apr 16, 2025

can the other reporters follow the steps above and check ?

@sunderme
Copy link
Member

you can also try the installer from here: https://github.com/texstudio-org/texstudio/actions/runs/14500808920

It removes all dlls before copying the new ones.

@mroman-ibs
Copy link
mroman-ibs commented Apr 17, 2025

I've uninstalled TeXStudio, removed its entire folder, and then reinstalled the app (4.8.6). It still crashes when using pdfviewer for the files with many figures. BTW - I'm not completely sure, but the errors have started to appear after updating my tex from TexLive 2024 to 2025...

@pkabal
Copy link
pkabal commented Apr 17, 2025

When I encountered the problems with version 4.8.6, on my desktop computer, I tried 4.87 beta2, and 4.8.5 and the problems continued. Downgrading to 4.84 worked. I then realized that I had a working version of 4.8.6 on my laptop which continued to work properly on the same source file. I started comparing the installations and then noticed the date stamps on the files in the generic subfolder in the installation were older than the rest of the installation. That prompted me to suggest deleting the texstudio folder in Program Files.

I will add that at some point I made sure that my MiKTeX installation was up to date, including running 'refresh the file name database', under the Tasks tab.

Hope that helps.

@mroman-ibs
Copy link

Version 4.8.4 works. All newer versions (including 4.8.7RC) crash when the internal pdfviewer is used for the output pdf file with many pdf figures embedded inside. However, 4.8.5 worked with TexLive 2024, so the problem is somehow related also to the new version of TexLive. I would like to help, but no log file can be found to point out the source of the error. Is there a way to force the creation of such a debug file?

@sunderme
Copy link
Member

you can compile txs locally and try to run the debugger. See also https://github.com/texstudio-org/texstudio/wiki/Compiling

@octaeder
Copy link
Contributor

As a first try I moved (drag&drop) test1.pdf to the windowed internal pdf-viewer and txs crashed. I tried also with no-session option or Open dialog from txs main window and pdf-viewer window. But I still couldn't find a procedure how to reproduce. Most of the time it works. I can switch the viewer from windowed to embedded, then enlarge and shrink the viewer. No direct issues here. Acrobat and pdf24 no issues. Environment info:

Win 10 pro
msys2/ucrt64 latest
TeXstudio 4.8.7 (git 4.8.7rc1) as local/private msys2 build
Using Qt Version 6.9.0, compiled with Qt 6.9.0 R

My builds always run with debug option and following messages appeared on loading the pdf:

"Error: Couldn't find a font for 'Times-Roman', subst is 'Helvetica'"
"Error: No display font for 'Symbol'"

No crash information in the msys2 console.

Since no information are available on how the tex file should be build, I didn't try that.

Is the number of images really important? One of my tex documents I'm working on contains about 230 tikz images. These appear in several files (about 40) included from the main or included files. The final pdf has a size of about 8.6MB. The two eps images containded in test1.pdf have a size of less or equal to 100kB with about 6'000 lines each. This looks not very large to me.

@ARockhill
Copy link

Win10 Enterprise
TeXstudio 4.8.7 (git 4.8.7)
Using Qt Version 6.9.0, compiled with Qt 6.9.0 R

Unfortunately, I cannot share the .pdf or .tex docs due to corporate data control but did want to say I am having the same issue. It started with 4.8.6 but has continued after installing 4.8.7.

It doesn't happen all the time. Initially, I noticed that TeXstudio kept silently crashing when I was first invoking the app. It seemed to happen when attempting to load the .pdf in the built-in viewer. I went into user>AppData > Roaming > texstudio and deleted the lastSession.txss2 and was then able to start up. However, when I tried to load the session manually, it crashed again. I opened the root document and recompiled and it worked. I've been through this cycle several times and even with different documents. Did something change in 4.8.6?

If I can contribute to trouble shooting in any way shy of sharing the documents (I know...), please let me know and I'll do my best.

@sunderme
Copy link
Member

you can look if a backtrace is there. Or better compile txs with debug info and run it in a debugger.
But in the end, a test case is necessary.

@sunderme
Copy link
Member

the original crash, I consider solved.
I need a complete test case to evaluate any other crashes.

@Ame-sakura
Copy link
Author

最初的崩溃问题我认为已经解决了。 我需要一个完整的测试用例来评估其他崩溃问题。

is the problem fixed in version 4.8.8beta4? or any other version?
in 4.8.8beta4 the crash still exists.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants
0