[GH-ISSUE #280] Windows CPAL Panic #200

Open
opened 2026-02-28 14:31:19 +03:00 by kerem · 2 comments
Owner

Originally created by @DusterTheFirst on GitHub (Feb 9, 2022).
Original GitHub issue: https://github.com/jpochyla/psst/issues/280

Describe the bug
When attempting to play a song, a the song does not play and nothing seems to happen. Running the gui from the console, one can see a panic message as soon as the playback is requested.

Panic

thread 'cpal_wasapi_out' panicked at 'index out of bounds: the len is 1 but the index is 1', psst-core\src\audio\source.rs:70:13
stack backtrace:
   0:     0x7ff67c6ee27f - <unknown>
   1:     0x7ff67c70745a - <unknown>
   2:     0x7ff67c6e6398 - <unknown>
   3:     0x7ff67c6f0b56 - <unknown>
   4:     0x7ff67c6f0535 - <unknown>
   5:     0x7ff67c6f11b5 - <unknown>
   6:     0x7ff67c6f0d9b - <unknown>
   7:     0x7ff67c6eeba7 - <unknown>
   8:     0x7ff67c6f0cf9 - <unknown>
   9:     0x7ff67c731810 - <unknown>
  10:     0x7ff67c7317d7 - <unknown>
  11:     0x7ff67c4a11dd - <unknown>
  12:     0x7ff67c4535f0 - <unknown>
  13:     0x7ff67c5e4405 - <unknown>
  14:     0x7ff67c460adb - <unknown>
  15:     0x7ff67c49ae36 - <unknown>
  16:     0x7ff67c6f4cbc - <unknown>
  17:     0x7ffcb46e7034 - BaseThreadInitThunk
  18:     0x7ffcb4ca2651 - RtlUserThreadStart

Environment

Originally created by @DusterTheFirst on GitHub (Feb 9, 2022). Original GitHub issue: https://github.com/jpochyla/psst/issues/280 **Describe the bug** When attempting to play a song, a the song does not play and nothing seems to happen. Running the gui from the console, one can see a panic message as soon as the playback is requested. **Panic** ``` thread 'cpal_wasapi_out' panicked at 'index out of bounds: the len is 1 but the index is 1', psst-core\src\audio\source.rs:70:13 stack backtrace: 0: 0x7ff67c6ee27f - <unknown> 1: 0x7ff67c70745a - <unknown> 2: 0x7ff67c6e6398 - <unknown> 3: 0x7ff67c6f0b56 - <unknown> 4: 0x7ff67c6f0535 - <unknown> 5: 0x7ff67c6f11b5 - <unknown> 6: 0x7ff67c6f0d9b - <unknown> 7: 0x7ff67c6eeba7 - <unknown> 8: 0x7ff67c6f0cf9 - <unknown> 9: 0x7ff67c731810 - <unknown> 10: 0x7ff67c7317d7 - <unknown> 11: 0x7ff67c4a11dd - <unknown> 12: 0x7ff67c4535f0 - <unknown> 13: 0x7ff67c5e4405 - <unknown> 14: 0x7ff67c460adb - <unknown> 15: 0x7ff67c49ae36 - <unknown> 16: 0x7ff67c6f4cbc - <unknown> 17: 0x7ffcb46e7034 - BaseThreadInitThunk 18: 0x7ffcb4ca2651 - RtlUserThreadStart ``` **Environment** - OS: - Edition: Windows 10 Enterprise - Version: 21H2 - OS build: 19044.1503 - Experience: Windows Feature Experience Pack 120.2212.3030.0 - Version: https://nightly.link/jpochyla/psst/actions/runs/1748008154/Psst.exe.zip
Author
Owner

@jpochyla commented on GitHub (Mar 12, 2022):

Hi, your audio output has only one channel (mono), and Psst is doing only very rudimentary channel mapping. Either way, I doubt you actually want to listen to music on mono. Is your setup indeed limited in this way, or is the output selection logic wrong?

<!-- gh-comment-id:1065976977 --> @jpochyla commented on GitHub (Mar 12, 2022): Hi, your audio output has only one channel (mono), and Psst is doing only very rudimentary channel mapping. Either way, I doubt you actually want to listen to music on mono. Is your setup indeed limited in this way, or is the output selection logic wrong?
Author
Owner

@DusterTheFirst commented on GitHub (Mar 13, 2022):

My audio output is not mono. The output logic most probably is selecting the wrong output format.

<!-- gh-comment-id:1066050918 --> @DusterTheFirst commented on GitHub (Mar 13, 2022): My audio output is not mono. The output logic most probably is selecting the wrong output format.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/psst#200
No description provided.