Skip to content

Regression: Unable to update add-ons containing dynamic link libraries. #14991

@cary-rowen

Description

@cary-rowen

Steps to reproduce:

  1. Install this add-on: https://github.com/cary-rowen/AudioControl/releases/download/v1.8.1/AudioControl-1.8.1.nvda-addon
  2. After the add-on has been installed and restarted, try installing it again to simulate the update process.

Actual behavior:

You will get an error:Failed to install add-on from D:\audioControl-1.8.1.nvda-addon
Error log snippet:

ERROR - gui.addonGui.installAddon (09:25:32.966) - MainThread (3700):
Error installing  addon bundle from D:\audioManager-1.0.0.nvda-addon
Traceback (most recent call last):
  File "addonHandler\__init__.pyc", line 464, in completeRemove
PermissionError: [WinError 5] 拒绝访问。: 'C:\\Users\\cary\\AppData\\Roaming\\nvda\\addons\\audioManager' -> 'C:\\Users\\cary\\AppData\\Roaming\\nvda\\addons\\tmpbzig4yv2.delete'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "gui\addonGui.pyc", line 553, in installAddon
  File "addonHandler\__init__.pyc", line 438, in requestRemove
  File "addonHandler\__init__.pyc", line 466, in completeRemove
RuntimeError: Cannot rename add-on path for deletion

Restarting NVDA gives the following error:

ERROR - addonHandler.Addon.completeInstall (09:34:02.103) - MainThread (808):
Failed to complete addon installation for audioControl
Traceback (most recent call last):
  File "addonHandler\__init__.pyc", line 429, in completeInstall
FileExistsError: [WinError 183] 当文件已存在时,无法创建该文件。: 'C:\\Users\\cary\\AppData\\Roaming\\nvda\\addons\\audioControl.pendingInstall' -> 'C:\\Users\\cary\\AppData\\Roaming\\nvda\\addons\\audioControl'
DEBUG - addonHandler._getAvailableAddonsFromPath (09:34:02.264) - MainThread (808):
Found add-on audioControl - 1.8.1. Requires API: (2022, 4, 0). Last-tested API: (2023, 1, 0)
DEBUG - addonHandler._getAvailableAddonsFromPath (09:34:02.264) - MainThread (808):
Loading add-on from C:\Users\cary\AppData\Roaming\nvda\addons\audioControl.pendingInstall
DEBUG - addonHandler.Addon.__init__ (09:34:02.264) - MainThread (808):
Using manifest translation from C:\Users\cary\AppData\Roaming\nvda\addons\audioControl.pendingInstall\locale\zh_CN\manifest.ini

Expected behavior:

The add-on is installed without popping up an error dialog, although the old add-on directory cannot be deleted immediately because it contains occupied files(DLL files).
After the next restart of NVDA, the old add-on directory is deleted and the add-on is updated.
This is the behavior of NVDA-2023.1

NVDA logs, crash dumps and other attachments:

Logs have been provided above.

System configuration

NVDA installed/portable/running from source:

installed and portable

NVDA version:

alpha-28387

Windows version:

Windows 10 22H2 (AMD64) build 19045.2965

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

None

Other information about your system:

None

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.

NVDA-2023.1 cannot reproduce.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature/addon-storeFeatures / behavior of the add-on Storep3https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#prioritytriagedHas been triaged, issue is waiting for implementation.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions