Awalz / SwiftyCam

A Snapchat Inspired iOS Camera Framework written in Swift
BSD 2-Clause "Simplified" License
2.08k stars 327 forks source link

crash when run on simulator "collection was mutated while being enumerated" #236

Open Guala99 opened 3 years ago

Guala99 commented 3 years ago

When running Camera on simulator it always crashes and I receive this error

Terminating app due to uncaught exception 'NSGenericException', reason: '*** Collection <NSConcreteHashTable: 0x600002c15c20> was mutated while being enumerated.'

When I run it on a physical device It works fine tho

Eirias commented 3 years ago

It's not possible to access camera of your development machine to be used as simulator camera. Camera functionality is not available in any iOS version and any Simulator. You will have to use device for testing camera purpose.

Guala99 commented 3 years ago

@Eirias thank you for your answer, so let's say a real device doesn't have front or rear camera because, for example, they are broken. Will this error occur? or it will not because It appears only on simulator?