capacitor-community / capacitor-community/native-audio

iOS picking volume as Date natively

Open
#128 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
154
Forks
78
PR merge metrics
No merged PRs in 30d

Description

**Describe the bug**
I've seen that when volume is not set in PreloadOptions, sometimes I get the following error:

*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[__NSTaggedDate count]: unrecognized selector sent to instance 0x8000000000000000'

Which seems to be caused by volume being understood as a NSDate.

**To Reproduce**
Steps to reproduce the behavior:
1. Preload an audio without setting volume

**Expected behavior**
It shouldn't crash

**Desktop (please complete the following information):**
- OS: iOS
- Browser safari

**Smartphone (please complete the following information):**
- Device:iPhone 16 simulator
- OS: iOS 8.4

Contributor guide

Open the contributing guide

Research direction

Start at the iOS handling of PreloadOptions, focusing on the preload-audio path when volume is omitted. Reproduce the crash on the reported iPhone 16 simulator setup and trace why volume is treated as a date; done means preloading without volume no longer crashes.

Written by the indexing model from the issue text.

Assessment

Tech stack
ios
Domain
mobile-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.