Topics

Re : Re: Re : Re: [nvda-addons] delayed character descriptions. #addonrequestreview

Cyrille
 

Hello
Not so sure that it would be a good workaround.
After the line that causes the error in cancelSpeech, there may still be a call to the cancel method of the synthesizer and some global variables setting.
At least if this workaround is implemented, a debug message should be printed in the log.
Regards,
Cyrille
----- Mail d'origine -----
De: Luke Davis <luke@...>
À: nvda-addons@nvda-addons.groups.io
Envoyé: Tue, 17 Sep 2019 08:16:48 +0200 (CEST)
Objet: Re: Re : Re: [nvda-addons] delayed character descriptions. #addonrequestreview
I am one of those people who think that 2019.2 (or 2019.2.1) will probably be
around for quite a while, so if this can be fixed, it should be.
I hate to be so general about it, but would putting a try around the call to
origCancelSpeech() on line 37, catching ValueError, and passing, solve this?
Luke

On Mon, 16 Sep 2019, Cyrille via Groups.Io wrote:
> Hello David
> As I have told you before, the test was done on a fresh NVDA 2019.2 portable version. When I perform test on portable versions, I usually use one version
> per add-on.
> To be sure, I have re-created a fresh portable NVDA 2019.2 directly from installer. And have installed only your add-on on this NVDA. So no conflict with
> other add-ons.
> I have tried to reproduce the issue with various synthesizer and have had a little difficulty.
> I have finally succeeded in reproducing the issue with eSpeak, delay=200ms and calling many character navigation commands. Log attached; search for
> "traceback" to look at the part where there is the error.
> The log shows that the issue occurs in a part of the cancelSpeech function present in 2019.2 but that have disappeared in the last alpha, probably due to
> audio reorganization:
> if _speakSpellingGenerator:
>     _speakSpellingGenerator.close()
> So I wonder if it is worth to try to track a bug that may be disappearing in the next NVDA version.
> ----- Mail d'origine -----
> De: DaVid <dhf360@...>
> À: nvda-addons@nvda-addons.groups.io
> Envoyé: Mon, 16 Sep 2019 06:16:59 +0200 (CEST)
> Objet: Re: [nvda-addons] delayed character descriptions. #addonrequestreview
> For derek and Luke: I agree with you. I really don't use this feature,
> but is useful for many users. Some synths don't have good character
> pronunciations, some people have hearing loss.
> I feel some users have considered it a waste of time. I'm just saying,
> we should consider all use cases.
> Another case I discovered today, I'm learning Portuguese. For testing
> purposes I always have this add-on enabled, and I realized that it is
> very useful when starting with a new language.
> For Cyrille: Can you test it with another add-ons disabled? maybe
> another add-ons patched the speech methods also, and generated those
> issues.
> I can't reproduce it on my computers. We should use thread locks, but
> NVDA's speech methods seem to be thread unsafe and I don't want to
> patch more NVDA's code.
> I want to keep this add-on as simpler as possible.
> For luke: I changed it to GPL2. When I created the repo I selected 3.0
> on github,but at some point an older licence file from another add-on
> replaced it. I used a template that I had prepared for another add-on
> and forgot it.
> I don't like to distribute licence files on add-ons, is good for a
> complete software as NVDA, but in plug-ins... I don't want the user
> ends with many licence files about the same thing.
> I don't care about headers in these small code pieces, but even NVDA
> code omits it in the files I have seen.
> About pep 8, I follow those standards in a company professional
> project. But not in personal projects. E.G. they recommend to use
> spaces and I don't like to use spaces on my projects.
> I updated the mistakes in the documentation, and changed the channel to dev.
> About the fake timer. That timer is not executed. Its just to avoid
> checking the existence of a timer if the timer need to be cancelled.
> That condition is False for the first time only. So, set a fake timer
> doesn't affect the code functionality.
> Milliseconds field: I think that the user can deal with it. For
> personal use, I prefer to edit only one field and not two.
> Regards,
> DaVid.
> H
>
>
>
--
Luke Davis
Moderator: the new NVDA Help mailing list! (https://groups.io/g/NVDAHelp)
Author: Debug Helper NVDA add-on (https://addons.nvda-project.org/addons/debugHelper.en.html)

Luke Davis
 

On Tue, 17 Sep 2019, Cyrille via Groups.Io wrote:

Not so sure that it would be a good workaround.
After the line that causes the error in cancelSpeech, there may still be a call to the cancel method of the synthesizer and some global variables setting.
At least if this workaround is implemented, a debug message should be printed in the log.
I agree it is not great, that's what I meant about "I hate to be so general about it"--I don't like catching such a general warning. That could probably be improved by examining the exception details.

But for testing, it would at least tell us if doing some version of that solves the problem. Could you try it? I haven't replicated it yet.

This add-on has already started getting some traction on one of the users lists from somebody having posted about it in answer to a question.

Luke