Re: Exception thrown sometimes on NVDA start, maybe related to Updater?


James Scholes
 

To be clear, checking for version info in this way is a bit of a hack, and you aren't doing any exception handling locally to catch the lack of matching groups from the regular expression. So there could definitely be a server-side inconsistency, but you can't rely on the server returning the correct data at all times and not validate it.

Regards,

James Scholes

On 22/05/2020 at 12:34 pm, Joseph Lee wrote:
Hi,
Does Add-on Updater function after you get this exception i.e. does "check
for add-on updates" show up under tools menu? If yes, it might be a version
check issue for at least one add-on (likely a server-side issue).
Cheers,
Joseph
-----Original Message-----
From: nvda-addons@nvda-addons.groups.io <nvda-addons@nvda-addons.groups.io>
On Behalf Of Doug Lee
Sent: Friday, May 22, 2020 9:54 AM
To: nvda-addons@nvda-addons.groups.io
Subject: [nvda-addons] Exception thrown sometimes on NVDA start, maybe
related to Updater?
I get this often on the first reload of NVDA after an add-on updater update
of add-ons. Today though, I got the following exception without any updates.
I have my NVDA set up to tell me of issues that normally go undetected, so
this may be common but unreported; not sure. I also suspect it means one of
my add-ons has a malformed manifest.ini line?
NVDA initialized
INFO - logging.Logger.info (12:42:19.116) - MainThread (39876):
Performing automatic update check
ERROR - stderr (12:42:19.796) - Thread-7 (35516):
Exception in thread Thread-7:
Traceback (most recent call last):
File "threading.pyc", line 926, in _bootstrap_inner
File "threading.pyc", line 870, in run
File
"C:\Users\Doug\AppData\Roaming\nvda\addons\addonUpdater\globalPlugins\addonU
pdater\addonHandlerEx.py", line 158, in fetchAddonInfo
version = re.search("(?P<name>)-(?P<version>.*).nvda-addon",
addonUrl.split("/")[-1]).groupdict()["version"]
AttributeError: 'NoneType' object has no attribute 'groupdict'

Join nvda-addons@nvda-addons.groups.io to automatically receive all group messages.