-
-
Notifications
You must be signed in to change notification settings - Fork 175
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
Crash reports sent only after second launch, not immediately after app restart #1114
Comments
Hi @dalnoki. Thanks for the report!
No crash report will be written to disk if the user terminates/restarts the program from the I recommend using macOS' service-manager |
Hey @supervacuus the customer shared the following: "Also worth mentioning that we can reproduce the issue on Ubuntu as well. I want to highlight that disabling the reboot does not solve the issue. We have tried this at an early stage and it's did not work. And we are spawning a completely new instance of our app, so it should not interfere with Sentry SDK's work." |
Hi @supervacuus , I want to highlight that I can see a ".envelope" file created in the database path after the crash. however for some reason it does not get picked up and sent on the immediate run after the crash (regardless our reboot hook enabled or disabled) |
Thanks. The crash handler could finish processing if an
One reason for the described behavior could be that a previous run still locks the crashed run. We introduced file locks so multiple processes could share a database path without interfering with their runs (i.e., each run directory is locked as long as a Native SDK using process keeps their file descriptor alive). Is it possible that the crashed process is still being executed while you initialize the Native SDK in the newly started process? This would explain why it doesn't get picked up on the start "following" the crash but does get picked up on the next. Keep in mind that the file locks depend on the file descriptors being released. This means that any forked/spawned process that inherits file descriptors from main process could hold on to it longer than you'd expect. |
Thank you for the reply! Does it mean there's noway to reboot our application from the crashed process? Can we force Sentry SDK to process these envlopes after the initialization? |
Description
A customer is encountering an issue with the timing of crash report submissions in a Qt-based application using Sentry Native with Breakpad as the backend. When the application crashes, they use the on_crash hook to restart the app immediately. However, crash reports are only appearing in Sentry after the second launch of the application, not after the app is restarted due to the crash. This delay in sending crash reports is problematic, as the app runs as a background service and relying on users to manually restart it would result in unacceptable delays in receiving crash reports.
When does the problem happen
Environment
Steps To Reproduce
Please find a video recording of the issue in the shadow Jira ticket.. The issue is reproducible on the latest SDK version as well.
The text was updated successfully, but these errors were encountered: