element-hq / element-web

A glossy Matrix collaboration client for the web.
https://element.io
GNU Affero General Public License v3.0
11.21k stars 2k forks source link

The second time you send a voice message the waveform lags reality by ~1 second #22585

Open ara4n opened 2 years ago

ara4n commented 2 years ago

Steps to reproduce

  1. Send a VM on a fresh Element instance, as per https://github.com/vector-im/element-web/issues/22584
  2. Send another one - e.g. say "1, 2, 3, 4, 5"
  3. Rejoice that you get a waveform preview!
  4. Hit send
  5. Play it back, and discover that the waveform lags reality by about 1 second, and so the last second is truncated - for instance, it will show peaks for only "1, 2, 3, 4"

Outcome

What did you expect?

Waveform should not be truncated and match the reality of the message

What happened instead?

Waveform lags the reality by 1s and is truncated., so you can't reliably scrub within it, and it doesn't show an accurate representation of the message contents.

Operating system

macOS 12

Browser information

Chrome 102

URL for webapp

pr8843--matrix-react-sdk.netlify.app

Application version

pr8843

Homeserver

matrix.org

Will you send logs?

No

ara4n commented 2 years ago

For instance, this is me repeating the same message (1,2,3,4,5) with the same timing one after another:

Screenshot 2022-06-14 at 23 25 19

The first one was okay (modulo bug #22584). The second one only shows the first 4 digits.