Skip to content

Commit 68e26a0

Browse files
committed
Fix playrec() to allow 'data' to be arbitrary sequence type
1 parent b5e50e0 commit 68e26a0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sounddevice.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -422,7 +422,7 @@ def playrec(data, samplerate=None, channels=None, dtype=None,
422422
ctx = _CallbackContext()
423423
output_frames = ctx.check_data(data, output_mapping)
424424
if dtype is None:
425-
dtype = data.dtype # ignore module defaults
425+
dtype = ctx.data.dtype # ignore module defaults
426426
input_frames = ctx.check_out(out, output_frames, channels, dtype,
427427
input_mapping)
428428
if input_frames != output_frames:

0 commit comments

Comments
 (0)