cartertemm / AI-content-describer

NVDA add-on that provides descriptions for controls and images, powered by GPT4
GNU General Public License v2.0
48 stars 24 forks source link

NVDA doesn't start after updating to Version 2023.03.29 #19

Closed rperez030 closed 7 months ago

rperez030 commented 7 months ago

I plan to update this issue with information from the log later, but wanted to open it since yt may be affecting others. I'm running NVDA 2023.3.4.

cartertemm commented 7 months ago

Interesting. I can't think of a situation where the screen reader itself would have trouble starting after installing the addon, and haven't run into this myself, but definitely sounds like something I need to fix before an official release. Looking forward to seeing the log output.

rperez030 commented 7 months ago

Here is the log generated with a new copy of NVDA and just this add-on. For context, this is the ARM version of Windows 11.

TestAIContentDescriber.log

rperez030 commented 7 months ago

another interesting fact. I updated to NVDA 2024.1 and enabled the add-on overriding compatibility. It didn't crash, however, generated the following warnings an errors.

WARNING - stdout (22:34:05.195) - Thread-2 (threaded_imports) (10524):
OpenCV bindings requires "numpy" package.
WARNING - stdout (22:34:05.195) - Thread-2 (threaded_imports) (10524):
Install it via command:
WARNING - stdout (22:34:05.195) - Thread-2 (threaded_imports) (10524):
    pip install numpy
ERROR - logHandler._threadExceptHook (22:34:05.195) - Thread-2 (threaded_imports) (10524):
Exception in thread Thread-2 (threaded_imports):
Traceback (most recent call last):
  File "C:\addontest\userConfig\addons\AIContentDescriber\globalPlugins\AIContentDescriber\numpy\core\__init__.py", line 22, in <module>
    from . import multiarray
  File "C:\addontest\userConfig\addons\AIContentDescriber\globalPlugins\AIContentDescriber\numpy\core\multiarray.py", line 12, in <module>
    from . import overrides
  File "C:\addontest\userConfig\addons\AIContentDescriber\globalPlugins\AIContentDescriber\numpy\core\overrides.py", line 7, in <module>
    from numpy.core._multiarray_umath import (
ModuleNotFoundError: No module named 'numpy.core._multiarray_umath'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "threading.pyc", line 1045, in _bootstrap_inner
  File "threading.pyc", line 982, in run
  File "C:\addontest\userConfig\addons\AIContentDescriber\globalPlugins\AIContentDescriber\__init__.py", line 61, in threaded_imports
    import cv2
  File "C:\addontest\userConfig\addons\AIContentDescriber\globalPlugins\AIContentDescriber\cv2\__init__.py", line 11, in <module>
    import numpy
  File "C:\addontest\userConfig\addons\AIContentDescriber\globalPlugins\AIContentDescriber\numpy\__init__.py", line 150, in <module>
    from . import core
  File "C:\addontest\userConfig\addons\AIContentDescriber\globalPlugins\AIContentDescriber\numpy\core\__init__.py", line 48, in <module>
    raise ImportError(msg)
ImportError: 

IMPORTANT: PLEASE READ THIS FOR ADVICE ON HOW TO SOLVE THIS ISSUE!

Importing the numpy C-extensions failed. This error can happen for
many reasons, often due to issues with your setup or how NumPy was
installed.

We have compiled some common reasons and troubleshooting tips at:

    https://numpy.org/devdocs/user/troubleshooting-importerror.html

Please note and check the following:

  * The Python version is: Python3.11 from "C:\addontest\nvda.exe"
  * The NumPy version is: "1.21.6"

and make sure that they are the versions you expect.
Please carefully study the documentation linked above for further help.

Original error was: No module named 'numpy.core._multiarray_umath'

if I try to use the face detection feature, I get the following error:

IO - inputCore.InputManager.executeGesture (22:28:14.055) - winInputHook (8456):
Input: kb(laptop):NVDA+shift+j
ERROR - scriptHandler.executeScript (22:28:14.055) - MainThread (11992):
error executing script: <bound method GlobalPlugin.script_describe_face of GlobalPlugin ('globalPlugins.AIContentDescriber')> with gesture 'NVDA+shift+j'
Traceback (most recent call last):
  File "scriptHandler.pyc", line 295, in executeScript
  File "C:\addontest\userConfig\addons\AIContentDescriber\globalPlugins\AIContentDescriber\__init__.py", line 391, in script_describe_face
    self.describe_face()
  File "C:\addontest\userConfig\addons\AIContentDescriber\globalPlugins\AIContentDescriber\__init__.py", line 252, in describe_face
    return threading.Thread(target=self.detection_interface.run).start()
                                   ^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'GlobalPlugin' object has no attribute 'detection_interface'
cartertemm commented 7 months ago

This issue should be fixed with the latest release (version 2024.04.14). Feel free to give that a try.

rperez030 commented 7 months ago

This is working well for me. Thank you so much for the improvements.