sendspin daemon --audio-device "my_alsa_device" should not try reaching a pulseaudio server

Open
#272 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
68/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Quiet
Tech stack
python
Domain
cli

Research direction

Start in sendspin/cli.py at _run_client_mode and then inspect sendspin/audio_devices.py, where sounddevice is imported and the audio device is resolved. Reproduce the command with the ALSA device from the report on a system without PulseAudio. Done means selecting that device no longer attempts to connect to a PulseAudio server.

Written by the indexing model from the issue text.

Description

Env:

  • Kernel/Arch: 6.18.38-current-sunxi / armv7l
  • OS: Ubuntu 26.04
  • sendpin-cli 7.5.0
  • No Pulseaudio software installed or running.

Steps

$ /root/.local/bin/sendspin daemon --log-level DEBUG --name "P0" --audio-device "plughw:CARD=Lite,DEV=0" --hardware-volume true

Note: plughw:CARD=Lite,DEV=0 is a ALSA device.

Logs

Traceback (most recent call last):
  File "/root/.local/bin/sendspin", line 6, in <module>
    sys.exit(main())
             ~~~~^^
  File "/root/.local/share/pipx/venvs/sendspin/lib/python3.14/site-packages/sendspin/cli.py", line 782, in main
    return asyncio.run(_run_client_mode(args))
           ~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.14/asyncio/runners.py", line 204, in run
    return runner.run(main)
           ~~~~~~~~~~^^^^^^
  File "/usr/lib/python3.14/asyncio/runners.py", line 127, in run
    return self._loop.run_until_complete(task)
           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^
  File "/usr/lib/python3.14/asyncio/base_events.py", line 719, in run_until_complete
    return future.result()
           ~~~~~~~~~~~~~^^
  File "/root/.local/share/pipx/venvs/sendspin/lib/python3.14/site-packages/sendspin/cli.py", line 798, in _run_client_mode
    from sendspin.audio_devices import resolve_audio_device
  File "/root/.local/share/pipx/venvs/sendspin/lib/python3.14/site-packages/sendspin/audio_devices.py", line 10, in <module>
    import sounddevice
  File "/root/.local/share/pipx/venvs/sendspin/lib/python3.14/site-packages/sounddevice.py", line 2972, in <module>
    _initialize()
    ~~~~~~~~~~~^^
  File "/root/.local/share/pipx/venvs/sendspin/lib/python3.14/site-packages/sounddevice.py", line 2936, in _initialize
    _check(_lib.Pa_Initialize(), 'Error initializing PortAudio')
    ~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/root/.local/share/pipx/venvs/sendspin/lib/python3.14/site-packages/sounddevice.py", line 2836, in _check
    raise PortAudioError(errormsg, err, hosterror_info)
sounddevice.PortAudioError: Error initializing PortAudio: Unanticipated host error [PaErrorCode -9999]: 'PulseAudio_Initialize: Can't connect to server' [<error getting host API: -10000> error -1]
```
Dominant language
Python
Stars
190
Forks
36
Avg merge
11d 19h
Merged PRs (30d)
2

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Sendspin/sendspin-python-cli

All issues in Sendspin/sendspin-python-cli

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.