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

double yield statement in sayAll handler #6685

Closed
derekriemer opened this issue Dec 28, 2016 · 2 comments
Closed

double yield statement in sayAll handler #6685

derekriemer opened this issue Dec 28, 2016 · 2 comments
Labels
p3 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority

Comments

@derekriemer
Copy link
Collaborator

I'm not sure if this is intentional, but it seems to be a bug.
Line 176 sayAllHandler.py

index=lastSentIndex+1
		speech.speak([speech.IndexCommand(index)])
		while speech.getLastSpeechIndex()<index:
			yield
			yield
		# Some synths say they've handled the index slightly sooner than they actually have,
@feerrenrut feerrenrut added the p3 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority label Dec 28, 2016
@jcsteh
Copy link
Contributor

jcsteh commented Jan 2, 2017

It's intentional, if somewhat arbitrary. Those generators run every core tick (which is every 10 ms or so while a core generator exists) and there's no reason for say all to do stuff that often. Thus, we do a few extra yields to slow it down. This kind of sucks and is the last remaining chunk of core spinning. This would be far better handled by speech callbacks (#4877) when we get those.

We should still probably comment this, even though that code will be replaced eventually.

@LeonarddeR
Copy link
Collaborator

Fixed in #7599

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
Projects
None yet
Development

No branches or pull requests

4 participants