-
Notifications
You must be signed in to change notification settings - Fork 527
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
[Bug]: Duration info for Windows SystemMediaTransportControls incorrect #2621
Comments
I found some details about this issue, if the music natually ended and begin play the next one, Youtube Music website will reuse the same HTMLMediaElement (the document.querySelector('.video-stream') And they not reset the state of media element, seems like they only append new audio data slice to the let duration = new Date(document.querySelector('.video-stream').duration*1000);
console.log(duration.getMinutes()+":"+duration.getSeconds()); // 15:40
let currentTime = new Date(document.querySelector('.video-stream').currentTime*1000);
console.log(currentTime.getMinutes()+":"+currentTime.getSeconds()); // 14:38 But if we pressed the next music button, they will create a new Some solutions:
Maybe someone can have better idea to fix this issue. I also send a feedback of this issue to Google, hope they can fix this ASAP :) |
Nice find! I did fill in a feedback form to google/youtube about this when I created this issue, it does kinda feels like putting a bottled message in the ocean when doing it so I didn't have much hope :( |
|
Preflight Checklist
YouTube Music (Application) Version
3.6.2.0
Checklists
What operating system are you using?
Windows
Operating System Version
Windows 11 23H2 22631.4460
What CPU architecture are you using?
x64
Last Known Working YouTube Music (Application) version
No response
Reproduction steps
Expected Behavior
Position, StartTime and EndTime in SytemMediaTransportControls to be that of the current playing song/media.
Actual Behavior
Position and EndTime time in minutes seems to increase seconds stays correct.
For example:
first song 3:32
second song 3:41
EndTime in SystemMediaTransportControls 5:41 on the second song
Enabled plugins
Additional Information
Since this seems to be an issue with music.youtube.com both in MSEdge and Firefox I understand that it's unlikely you can do anything about this, but if you can do something that would be highly appreciated.
Thanks in advance for any of your time!
The text was updated successfully, but these errors were encountered: