Skip to content
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

Receiving error TypeError: must be real number, not _InputOutputPair when inputting extra_settings parameter into OutputStream constructor #562

Closed
288bb opened this issue Oct 9, 2024 · 3 comments · Fixed by #563

Comments

@288bb
Copy link

288bb commented Oct 9, 2024

The full log says

 myrecording = sd.OutputStream(samplerate=fs, blocksize=0, device=sd.default.device, channels=1, dtype="int32", latency=sd.default.latency, extra_settings=sd.WasapiSettings(False, False), callback=callback)
  File "C:\Users\*bleep*\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\sounddevice.py", line 1502, in __init__
    _StreamBase.__init__(self, kind='output', wrap_callback='array',
  File "C:\Users\*bleep*\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\sounddevice.py", line 825, in __init__
    _get_stream_parameters(kind, device, channels, dtype, latency,
  File "C:\Users\*bleep*\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\sounddevice.py", line 2704, in _get_stream_parameters       
    parameters = _ffi.new('PaStreamParameters*', (
TypeError: must be real number, not _InputOutputPair
@mgeier
Copy link
Member

mgeier commented Oct 9, 2024

Thanks for this report!

I have made a change in #563, can you please try if that works for you?

@288bb
Copy link
Author

288bb commented Oct 10, 2024

I don't know how to install updates from github, how do I?

@mgeier
Copy link
Member

mgeier commented Oct 10, 2024

Based on #563 (review), I assume you found that out in the meantime?

If not, it is documented here: https://python-sounddevice.readthedocs.io/en/0.5.0/CONTRIBUTING.html#development-installation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants