pulseaudio should not load module-x11-bell in gnome-shell

Bug #1827842 reported by Pierre-Antoine Champin
26
This bug affects 3 people
Affects Status Importance Assigned to Milestone
pulseaudio (Ubuntu)
Fix Released
Low
Unassigned
Disco
Fix Released
Low
Unassigned

Bug Description

* Impact
The package force load a bell sound which can conflicts with the user configuration

* Test case
- Enable a login sound in session
- Login into a GNOME/Ubuntu session
-> the configured sound should be played

* Regression potential
Try other desktop environments to make sure their login sound behaviour isn't changed, it shouldn't since the customization dropped was specific to the Ubuntu sound theme

-------------------

The package `pulseaudio` installs a startup script in `/etc/xdg/autostart/pulseaudio.desktop`,
which itself runs `/usr/bin/start-pulseaudio-x11`,
which loads a number of x11 related modules in `pulseaudio`.

One of these modules is `module-x11-bell`,
which makes `pulseaudio` play a sound each time a system bell is emitted
(usually by terminal applications, such as bash or vim).

This is redundant with gnome-shell, which is also able to handle the system bell
(through the gsetting key `org.gnome.desktop.sound event-sounds`).

The gnome system bell is directly configurable by the user (Settings > Sound),
so it should be preferred over pulseaudio's own system bell.

I suggest to patch the `/usr/bin/start-pulseaudio-x11`,
to avoid loading `start-pulseaudio-x11` if it detects it is running in Gnome Shell
(e.g. if GNOME_SHELL_SESSION_MODE is set).

Colin Watson (cjwatson)
affects: launchpad → pulseaudio (Ubuntu)
Revision history for this message
Sebastien Bacher (seb128) wrote :

Thank you for your bug report, indeed that line is an old Ubuntu diff and should probably be removed, I'm going to do that in the next upload

Changed in pulseaudio (Ubuntu):
importance: Undecided → Low
status: New → Triaged
Revision history for this message
Sebastien Bacher (seb128) wrote :

The request makes sense but I wonder if you saw any user visible impact? Trying on a recent disco installation, using the 'beep' command or press tab on a command line reflect the sound selected in gnome-control-center -> sound

Revision history for this message
Sebastien Bacher (seb128) wrote :

Could you provide the details asked in the previous comment?

Revision history for this message
Pierre-Antoine Champin (pchampin) wrote :

Sorry for the late answer.

In my case, the sound was the correct one, but it was played twice at the same time, causing some unpleasant saturation.

Furthermore, if I changed the sound in the Gnome control panel, than I would have two different sounds playing at the same time (the newly configure Gnome sound, plus the old one, played by module-x11-bell).

That being said, I have not tried it on a fresh disco install. Mine was installed a year ago, and upgraded to disco... It took me that much time to investigate the problem and report it ;-)

Revision history for this message
Sebastien Bacher (seb128) wrote :

Thanks, I can't confirm those problems but the patch seems indeed a distro divergence we don't need, remove it now in the packaging vcs
https://git.launchpad.net/~ubuntu-audio-dev/pulseaudio/commit/?id=227d3ade

Changed in pulseaudio (Ubuntu):
status: Triaged → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package pulseaudio - 1:12.2-2ubuntu4

---------------
pulseaudio (1:12.2-2ubuntu4) eoan; urgency=medium

  * debian/patches/0006-load-module-x11-bell.patch:
    - remove that old distro patch, it's undocumented, not needed since
      GNOME handles the login sound by itself and create issues in some
      cases (duplicate sound, not respecting the UI choice)
      (lp: #1827842)

  [ Hui Wang ]
  * d/p/0800-stream-restore-Don-t-restore-if-the-active_port-is-P.patch:
    - Don't restore the streams to sinks/sources with only unavailable ports
      (LP: #1834138)

 -- Sebastien Bacher <email address hidden> Fri, 28 Jun 2019 11:45:10 +0200

Changed in pulseaudio (Ubuntu):
status: Fix Committed → Fix Released
description: updated
Revision history for this message
Brian Murray (brian-murray) wrote : Please test proposed package

Hello Pierre-Antoine, or anyone else affected,

Accepted pulseaudio into disco-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/pulseaudio/1:12.2-2ubuntu3.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-disco to verification-done-disco. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-disco. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in pulseaudio (Ubuntu Disco):
status: New → Fix Committed
tags: added: verification-needed verification-needed-disco
Mathew Hodson (mhodson)
Changed in pulseaudio (Ubuntu Disco):
importance: Undecided → Low
Revision history for this message
Brian Murray (brian-murray) wrote : [pulseaudio/disco] verification still needed

The fix for this bug has been awaiting testing feedback in the -proposed repository for disco for more than 90 days. Please test this fix and update the bug appropriately with the results. In the event that the fix for this bug is still not verified 15 days from now, the package will be removed from the -proposed repository.

tags: added: removal-candidate
Revision history for this message
Pierre-Antoine Champin (pchampin) wrote :

Sorry (again) for the late reply.

I just got an opportunity to install a fresh ubuntu 19.04, so I thought I would give a try to the patch... But on this fresh install, I do not have the problem... (without even enabling proposed packaged).

I don't even understand *why* the x11-bell module is *not* loaded...
(I did install the ubuntu-sounds package, as this is a condition in start-pulseaudio-x11).

Revision history for this message
Sebastien Bacher (seb128) wrote :

1:12.2-2ubuntu3.1 is working fine and not creating regressions, even if the bug seems to not happen on every install which makes the fix harder to verify the change is right on principle, marking as verified

tags: added: verification-done verification-done-disco
removed: removal-candidate verification-needed verification-needed-disco
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Yeah, I guess this will have to do it for the verification. Please be sure to re-open the bug in case someone reports the issue as not being fixed in the end.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package pulseaudio - 1:12.2-2ubuntu3.1

---------------
pulseaudio (1:12.2-2ubuntu3.1) disco; urgency=medium

  * debian/patches/0006-load-module-x11-bell.patch:
    - remove that old distro patch, it's undocumented, not needed since
      GNOME handles the login sound by itself and create issues in some
      cases (duplicate sound, not respecting the UI choice)
      (lp: #1827842)

  [ Hui Wang ]
  * d/p/0800-stream-restore-Don-t-restore-if-the-active_port-is-P.patch:
    - Don't restore the streams to sinks/sources with only unavailable ports
      (LP: #1834138)

 -- Sebastien Bacher <email address hidden> Fri, 28 Jun 2019 11:45:10 +0200

Changed in pulseaudio (Ubuntu Disco):
status: Fix Committed → Fix Released
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Update Released

The verification of the Stable Release Update for pulseaudio has completed successfully and the package is now being released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.