keep icon indicating copy to clipboard operation
keep copied to clipboard

[🐛 Bug]: alert.mp3 playing at random time when navigating UI

Open imorph opened this issue 2 years ago • 9 comments

Describe the bug Unrelated music composition ("Into the fire" by ikoliks from artlist.io) playing during navigating UI after some time. I see it at least in Arc browser (chromium based)

To Reproduce Open UI and click here and there with sound on.

Expected behavior No unrelated music compositions during work with the system.

Additional context This is alert.mp3 from ./keep-ui/public/music/ that is playing, I understand that this was some kind of mock while there is no proper sounds of alert/incoming event other UI interactions, but it is kinda annoying =) There is no other way to disable it but mute tab completely.

imorph avatar Oct 24 '24 09:10 imorph

The issue with alert.mp3 playing at random times is due to the ReactPlayer component being set to play the sound whenever anyNoisyNow is true. This is determined by checking if any preset has should_do_noise_now set to true. To disable the sound without muting the tab completely, you can modify the condition that sets anyNoisyNow to false or adjust the logic that determines when should_do_noise_now is true. Alternatively, you can set the volume prop of ReactPlayer to 0 to effectively mute the sound:

<ReactPlayer
  url="/music/alert.mp3"
  playing={anyNoisyNow}
  volume={0} // Set volume to 0 to mute
  loop={true}
  width="0"
  height="0"
  playsinline
/>

This should prevent the sound from playing while still allowing other audio from the tab [1].

To continue talking to Dosu, mention @dosu.

dosubot[bot] avatar Oct 24 '24 09:10 dosubot[bot]

@imorph did you configure some preset to be noisy before?

shahargl avatar Oct 24 '24 14:10 shahargl

CleanShot 2024-10-24 at 17 24 31@2x

shahargl avatar Oct 24 '24 14:10 shahargl

@shahargl I made several, but I don't remember if i used that toggle. Some alerts that are coming from outside have isNoisy field set to true

imorph avatar Oct 24 '24 14:10 imorph

oh so this isn't a bug but a feature ^^

some users asked "noisy alerts" - to make some noise using isNoisy flag. I guess you have some script generating alerts?

shahargl avatar Oct 24 '24 14:10 shahargl

I guess you have some script generating alerts?

that is true, I have control over alert generation. So the easy fix is not send isNoisy flag and use other some custom field?

Still, some random music composition looks unrelated to anything alert'y, first time I heard it i was scared and did not understood what is happening =)

imorph avatar Oct 24 '24 16:10 imorph

yea the user who asked it have a NOC room where they have many screens so they need something with noise ^^

shahargl avatar Oct 24 '24 16:10 shahargl

So the easy fix is not send isNoisy flag and use other some custom field?

exactly

shahargl avatar Oct 24 '24 16:10 shahargl

Closing for now

shahargl avatar Oct 24 '24 17:10 shahargl