Skip to content
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

NVDA crashes after pc comes back from hibernation #16367

Open
burakyuksek opened this issue Apr 5, 2024 · 18 comments
Open

NVDA crashes after pc comes back from hibernation #16367

burakyuksek opened this issue Apr 5, 2024 · 18 comments
Labels
p3 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority triaged Has been triaged, issue is waiting for implementation.

Comments

@burakyuksek
Copy link

Steps to reproduce:

  1. Get windows to hibernate
  2. Turn pc back on

Actual behavior:

NVDA crashes

Expected behavior:

NVDA does not crash

NVDA logs, crash dumps and other attachments:

Log just after pc comes back from hibernation:
INFO - watchdog.waitForFreezeRecovery (01:16:54.018) - watchdog (18536):
Starting freeze recovery after 0.5014075000071898 seconds.
DEBUGWARNING - watchdog.waitForFreezeRecovery (01:16:54.217) - watchdog (18536):
Listing stacks for Python threads:
Python stack for thread 10748 (watchdog.CancellableCallThread.execute(<_FuncPtr object at 0x08AC66C0>)):
File "threading.pyc", line 1002, in _bootstrap
File "threading.pyc", line 1045, in _bootstrap_inner
File "watchdog.pyc", line 382, in run
File "threading.pyc", line 629, in wait
File "threading.pyc", line 327, in wait

Python stack for thread 18536 (watchdog):
File "threading.pyc", line 1002, in _bootstrap
File "threading.pyc", line 1045, in _bootstrap_inner
File "threading.pyc", line 982, in run
File "watchdog.pyc", line 159, in _watcher
File "watchdog.pyc", line 166, in waitForFreezeRecovery
File "logHandler.pyc", line 64, in getFormattedStacksForAllThreads

Python stack for thread 18080 (winInputHook):
File "threading.pyc", line 1002, in _bootstrap
File "threading.pyc", line 1045, in _bootstrap_inner
File "threading.pyc", line 982, in run
File "winInputHook.pyc", line 81, in hookThreadFunc

Python stack for thread 24500 (UIAHandler.UIAHandler.MTAThread):
File "threading.pyc", line 1002, in _bootstrap
File "threading.pyc", line 1045, in bootstrap_inner
File "threading.pyc", line 982, in run
File "UIAHandler_init
.pyc", line 544, in MTAThreadFunc
File "queue.pyc", line 171, in get
File "threading.pyc", line 327, in wait

Python stack for thread 21068 (ThreadPoolExecutor-0_0):
File "threading.pyc", line 1002, in _bootstrap
File "threading.pyc", line 1045, in _bootstrap_inner
File "threading.pyc", line 982, in run
File "concurrent\futures\thread.pyc", line 81, in _worker

Python stack for thread 23940 (synthDrivers._espeak.BgThread):
File "threading.pyc", line 1002, in _bootstrap
File "threading.pyc", line 1045, in _bootstrap_inner
File "synthDrivers_espeak.pyc", line 205, in run
File "synthDrivers_espeak.pyc", line 232, in _speak
File "synthDrivers_espeak.pyc", line 167, in callback
File "nvwave.pyc", line 926, in idle
File "nvwave.pyc", line 921, in sync

Python stack for thread 22496 (hwIo.ioThread.IoThread):
File "threading.pyc", line 1002, in _bootstrap
File "threading.pyc", line 1045, in _bootstrap_inner
File "hwIo\ioThread.pyc", line 258, in run

Python stack for thread 23128 (MainThread):
File "nvda.pyw", line 415, in
File "core.pyc", line 881, in main
File "wx\core.pyc", line 2262, in MainLoop
File "core.pyc", line 827, in Notify
File "queueHandler.pyc", line 97, in pumpAll
File "queueHandler.pyc", line 64, in flushQueue
File "nvwave.pyc", line 1033, in _idleCheck

System configuration

NVDA installed/portable/running from source:

İnstalled

NVDA version:

2024.1

Windows version:

win11 23h2

Name and version of other software in use when reproducing the issue:

Other information about your system:

Other questions

Does the issue still occur after restarting your computer?

Yes

Have you tried any other versions of NVDA? If so, please report their behaviors.

Previous version did not behave this way

If NVDA add-ons are disabled, is your problem still occurring?

Yes

Does the issue still occur after you run the COM Registration Fixing Tool in NVDA's tools menu?

Yes

@Adriani90
Copy link
Collaborator

Can you please post the complete log file here? It is important to see which actions where made directly before crashing.

Also can you check in %temp%
and in
appdata\local\crashdumps
folders if there is any crashdump generated for NVDA?

You can do this by

  1. Opening run with windows+r
  2. Type %temp%
  3. Search by letter n until you hear something about nvda crashdump and attach it here if it is from the date this issue occured
  4. Open run again
  5. Type appdata
  6. Go to the folder called "local"
  7. Go to crashdumps
  8. Look if there is any NVDA chrash dump from the date the issue occured and attach it here

@burakyuksek
Copy link
Author

Hello,
Alright, I have reprduced the issue. Here's the log:
nvda-old.log
I could find an nvda_crash .dmp file in temp, but it was not named with a date. But here it is just in case:
nvda_crash.dmp
I could not find a crashdumps folder in the appdata/local folder.

@XLTechie
Copy link
Contributor

XLTechie commented Apr 6, 2024 via email

@enessaribas
Copy link

I experience this too, only when NVDA is active, there is about a five second freeze at login. This is a fast laptop, and this shouldn't occur.

@brbrett
Copy link

brbrett commented Apr 6, 2024

Hi there,

I just wanted to pop in and request clarification about a few details about the crashing:

  1. Are you able to run the program after it crashes, or does it continue to crash?
  2. Does this issue only occur if you hibernate your computer? It seems Microsoft differentiates between sleep and hibernate, and I'm noticing that @XLTechie is having the problem when the computer sleeps and @burakyuksek is having the problem when the computer hibernates.

@enessaribas
Copy link

I experience it after computer sleeps. I disabled hybernate and don't have it available. It is a long pause, after the recovery, NVDA behaves norally

@XLTechie
Copy link
Contributor

XLTechie commented Apr 6, 2024 via email

@burakyuksek
Copy link
Author

Hello,
I can start NVDA fine after the issue occurrs. It does not continue to crash.
My pc has a strange problem where when I put it to sleep, the fan and the ssd continue running, so I don't think it can go to sleep mode normally. I'm not sure if this is related to the issue with wasapi.

@zstanecic
Copy link
Contributor

zstanecic commented Apr 6, 2024 via email

@burakyuksek
Copy link
Author

Hello,
Thank you very much for the explanation with the sleeping issue. I disabled modern standby and my pc gets into sleep mode normaly now.
Also, NVDA does not crash when my pc gets back from sleep and I cannot see any errors in the log.

@brbrett
Copy link

brbrett commented Apr 6, 2024

I assume you are talking about ACPI s0 low-power idle, which may let the fans and SSD still run.

However, I was under the impression that sleep and hibernate preserve system state (in this case, the NVDA program) unless you lose power in the sleep state (and even then it seems hybrid sleep can deal with that case). I'm not very familiar with the win32 API, but is it possible for there to be issues restoring the state of NVDA when waking from sleep/hibernate?

Edit: correction, microsoft says SOC systems with Modern Standby don't use S1 - S3 sleep, but they do have hibernate

@zstanecic
Copy link
Contributor

zstanecic commented Apr 6, 2024 via email

@burakyuksek
Copy link
Author

burakyuksek commented Apr 6, 2024

Hello,
@zstanecic Look at the following article:
https://www.makeuseof.com/windows-disable-modern-standby/
@brbrett I have no idea. Previous versions of NVDA were fine.

@brbrett
Copy link

brbrett commented Apr 6, 2024

Hi all,
In my opinion, disabiling modern standby may provide a workaround for this issue, but it doesn't address the root cause that may reoccur in future OS updates. Additionally, not everyone has the expertise or means to disable modern standby (I imagine this is especially the case for managed work computers).

For the sake of accessibility and keeping NVDA robust, I think we should continue to work on this issue.

I'm still very new to NVDA and open source projects so I'd love to hear others thoughts on my opinion.

Also, @XLTechie and @enessaribas if you decide to disable modern standby (even temporaily for testing this out) could you let us know if it fixes the issue? Thanks!

@burakyuksek
Copy link
Author

burakyuksek commented Apr 6, 2024 via email

@XLTechie
Copy link
Contributor

XLTechie commented Apr 6, 2024 via email

@brbrett
Copy link

brbrett commented Apr 6, 2024

@XLTechie The only way to know for sure is to use the method described by @zstanecic.

Using either the windows command prompt or powershell, type in powercfg /a and you will see a list like this:

The following sleep states are available on this system:
    Standby (S3)
    Hibernate
    Hybrid Sleep

The following sleep states are not available on this system:
    Standby (S1)
        The system firmware does not support this standby state.

    Standby (S2)
        The system firmware does not support this standby state.

    Standby (S0 Low Power Idle)
        The system firmware does not support this standby state.

    Fast Startup
        This action is disabled in the current system policy.

Modern standby is called "S0 low power idle." My desktop computer doesn't support modern standby and instead uses the S3 sleep state. If you are having trouble, you are welcome to copy paste the information from the command prompt.

@XLTechie
Copy link
Contributor

XLTechie commented Apr 6, 2024 via email

@gerald-hartig gerald-hartig added p3 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority triaged Has been triaged, issue is waiting for implementation. labels Apr 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p3 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority triaged Has been triaged, issue is waiting for implementation.
Projects
None yet
Development

No branches or pull requests

7 participants