I just added lock screen widgets through Xcode 14 RC. When sending it to TestFlight, the home screen widgets do not show on iOS 15 devices but show on iOS 16 ones. The home screen and lock screen widgets use the same file, but I have a switch on the WidgetFamily to show a different SwiftUI view for the lock screen and still use the same TimelineEntry for both widgets.
When trying to run the home screen widgets on an iOS 15 simulator, I get the error:
dyld[33054]: Symbol not found: _$s9WidgetKit0A6FamilyO15accessoryCorneryA2CmFWC
Referenced from: /Users/me/Library/Developer/CoreSimulator/Devices/0635BCE6-3EC3-44A8-AB14-7B41TED178F6/data/Containers/Bundle/Application/7EAAAAE2-737A-4D13-A142-C609A921WEDS/My App.app/PlugIns/MyAppWidgetExtension.appex/MyAppWidgetExtension
Expected in: /Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 15.5.simruntime/Contents/Resources/RuntimeRoot/System/Library/Frameworks/WidgetKit.framework/WidgetKit
As anyone experienced this / know how to fix this? Even when I take out my iOS 16 code the same error appears. I've been searching for hours trying to figure this out and no solution has helped yet.
Had same problem, managed to fix with removal of all .accessoryCorner
cases from WidgetFamily
switches across several files. Hope it helps you too.