Skip to content
This repository has been archived by the owner on Feb 25, 2023. It is now read-only.

Auto-play search result audio - playback issue #2055

Open
grospoulpe opened this issue Jan 30, 2022 · 3 comments
Open

Auto-play search result audio - playback issue #2055

grospoulpe opened this issue Jan 30, 2022 · 3 comments

Comments

@grospoulpe
Copy link

Description
It's been a while I've got that problem.
When I scan a word (displaying the popup with all the corresponding definition), I can see a blue flash line on top, but no audio playback. Then I try again, no blue flash line (for an already scanned word), but then audio playback works for all words I scan in the current page.
If I refresh the page, or go to another one: same problem; during the first scan, no audio play back. (but works on the next scan, or if I use a playback keyboard shortcut)

Browser version
Chrome Version 97.0.4692.99 (Official Build) (64-bit)
Microsoft Edge Version 97.0.1072.76 (Official build) (64-bit)

Yomichan version
Yomichan 21.10.31.1

Exported settings file
(If you think it might be relevant, create a settings export file using the Export Settings button on the settings page; zip or rename the resulting file to .txt to attach to the issue.)

@archiif
Copy link
Contributor

archiif commented Feb 12, 2022

I'm assuming you're using Auto-play search result audio? If so, I'm also having the same issue. You should consider renaming the issue's title for clarity.

I don't have an exact set of reproduction steps, but I think the bug behaves roughly like the way you described. Though in my case auto-play will also stop working randomly on other occasions, but I can't figure out an exact pattern.

@grospoulpe grospoulpe changed the title Audio playback issue Auto-play search result audio playback issue Feb 12, 2022
@grospoulpe grospoulpe changed the title Auto-play search result audio playback issue Auto-play search result audio - playback issue Feb 12, 2022
@toasted-nutbread
Copy link
Collaborator

This may be due to the following error that occurs when trying to play audio:

play() failed because the user didn't interact with the document first. https://goo.gl/xX8pDD

Basically this error is indicating that the user is expected to interact with the webpage before anything is allowed to be auto-played. So if you click on the page before scanning, the sound should play. Otherwise this error will silently occur.

However, I don't think this has always been the case for Chrome extensions. This may be a bug/regression.

@toasted-nutbread
Copy link
Collaborator

This has been reported as a Chromium bug in https://bugs.chromium.org/p/chromium/issues/detail?id=1312816, tracked in #2107.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants