Posts

Post not yet marked as solved
1 Replies
429 Views
I'm seeing this crash, new in iOS 17.2: *** Assertion failure in -[_UIPhysicalButtonInteraction _registerWithArbiterSkippingEvaluationAndObservation], _UIPhysicalButtonInteraction.m:823 Anyone know what it means or where I can find more info? I can't find any documentation on this.
Posted Last updated
.
Post not yet marked as solved
9 Replies
1.3k Views
I need to exchange small amounts of data in my app near realtime between users who could be anywhere with only an internet connection. One user is a Leader and needs to send data (just a few bytes) to all Followers - up to 30 - about each second. Then each Follower needs to send data (again, just a few bytes) back to the Leader about each second. The requirement is similar to the example app from last year's WWDC networking part 2 video called TicTacToe, except the users may not be local.I've tried using Game Center but can't get it right. I've been able to achieve most of my objectives with this GameKit implementation:Follower starts:[[GKLocalPlayer localPlayer] registerListener:self]; request = [[GKMatchRequest alloc] init]; request.minPlayers = 2; request.maxPlayers = 2; request.playerAttributes = 0x0000000F; request.playerGroup = groupName; [[GKMatchmaker sharedMatchmaker] findMatchForRequest:request...Leader starts:[[GKLocalPlayer localPlayer] registerListener:self]; request = [[GKMatchRequest alloc] init]; request.minPlayers = 2; request.maxPlayers = 2; request.playerAttributes = 0xFFFFFFF0; request.playerGroup = groupName; [[GKMatchmaker sharedMatchmaker] findMatchForRequest:request...You can update UI with the completion handlers, but don't count on a real match until:- (void)match:(GKMatch *)match player:(GKPlayer *)player didChangeConnectionState:(GKPlayerConnectionState)state { use the match / player combo to note the connection for both leader and follower. Add to array of followers for leader. If Leader, call your Leader starts code again }Send data to either with:[match sendData:encoder.encodedData toPlayers:playerArray dataMode:GKMatchSendData(Un)reliableerror:&error];and receive in:- (void)match:(GKMatch *)match didReceiveData:(NSData *)data forRecipient:(GKPlayer *)recipient fromRemotePlayer:(GKPlayer *)player { // you've got mail from player! } So far, so good. Here's the bad news: depending on network strength, connections disconnect regularly. Even though I've built in dependable reconnect code, it can take up to 15 seconds to reconnect so it really isn't a good "real-time" experience.I'm currently testing with various combinations of data size (sometimes pad it so it's heft may keep the connection) or frequency (sometimes just send a "poke me" message) or tweaking the reliable vs unreliable flag in the send message calls.I can get about 10 followers per leader on a good day, but other times, more than 3 followers cycle between connect, disconnect, reconnect in an unusable fashion.I'm still trying to make usable, but wanted to document my success/failures so far in hopes that I can help many and perhaps get help from a few.Any ideas would be welcomed and any tweaks will be tested and reported.
Posted Last updated
.
Post not yet marked as solved
8 Replies
2.5k Views
I use addItemWithProductID: in the code below to add an Apple Music track to the user's library. This is mature code that's worked fine previously. But now in iOS 14.0.1 it causes the app to freeze. I can trace when running from Xcode or the released app version from App Store and the app freezes after the line: NSLog(@"just before addItemWithProductID %@", productID); The ">>>added..." line is never called. Any idea as to how to remedy? (void) addAppleMusicTrackWithProductID: (NSString *) productID {         NSLog(@" addApplemUsic has been called for productID: %@", productID);         SKCloudServiceController *cloudServiceController;         cloudServiceController = [[SKCloudServiceController alloc] init];         [cloudServiceController requestCapabilitiesWithCompletionHandler:^(SKCloudServiceCapability capabilities, NSError * _Nullable error){             NSLog(@"capabilities: %lu error:%@", (unsigned long)capabilities, error);             if (capabilities >= SKCloudServiceCapabilityAddToCloudMusicLibrary)             {                 NSLog(@"just before addItemWithProductID %@", productID);                 [[MPMediaLibrary defaultMediaLibrary] addItemWithProductID:productID completionHandler:^(NSArray<__kindof MPMediaEntity *> * _Nonnull entities, NSError * _Nullable error) {                     NSLog(@">>>added %@ with %i entities: %@ and  error %@",productID, (int) entities.count, entities, error);                     NSArray *tracksToPlay = [NSArray arrayWithObject:productID];                     [musicPlayer setQueueWithStoreIDs:tracksToPlay];                     [musicPlayer play];                     NSLog(@">>>>now playing AM title:%@ | artist:%@", musicPlayer.nowPlayingItem.title, musicPlayer.nowPlayingItem.artist);                                      }];             }         }]; }
Posted Last updated
.
Post not yet marked as solved
14 Replies
4.0k Views
I get this error when trying to submit a beta build. App Store Connect Operation Error  ERROR ITMS-90334: "Invalid Code Signature Identifier. The identifier "com.apple.WK" in your code signature for "app name watch" must match its Bundle Identifier "com.appname.watchkitapp"" I don't know of anything that has changed with the code signing since last successful submission, can't find "com.apple.WK" anywhere in my project and have tried submitting a previous version with no changes and get the same error. Anyone have any idea what I could be doing wrong?
Posted Last updated
.
Post not yet marked as solved
1 Replies
702 Views
I've had several users report weird track progression in my app. There was no code changed in my app, but around the time of iOS16 or iOS16.1 users started reporting unexpected results from track progression when my app loads a playlist to MPMusicPlayer and lets the music player have control of track progression. A little more sleuthing has led me to see that often (though not always) when a playlist is loaded by creating an MPMediaItemCollection with saved mediaItems and using setQueueWithItemCollection to load to the music player, the first track plays as exected, but when the track end is reached and the music player should progress to the second track, instead it progresses to the third track. No stutter, no error and the logic of my app just follows the playing track, so my users have a bad experience. Is anyone else having this problem? If so, any ideas how to solve?
Posted Last updated
.
Post marked as solved
5 Replies
1.9k Views
I have an existing iOS app that uses MPMusicPlayerController systemMusicPlayer. When running on a MacBook with M1 processor, calling currentPlaybackTime returns 0 during play. Once paused, the correct playtime is returned. Anyone else having this issue or have an idea of how to get the correct playtime?
Posted Last updated
.
Post not yet marked as solved
0 Replies
865 Views
My iOS app targets fitness instructors and coaches and currently offers a free app with basic features and two in-app monthly subscriptions for two additional sets of features, which are marketed to the individual instructors/coaches. I've encouraged facilities to reimburse their instructors for individual subscriptions, but the facility deciders want something simple and a steady monthly rate. I'd like to add a subscription for facilities at a higher price point that would allow the facility to 'authorize' the features of the individual subscriptions to multiple instructors/coaches that are part of the facilty. For example, a facility subscription of $49/month could authorize up to 10 users to have the same feature set as the $10/month individual subscription. Does the app store have any models that work for this scenario? I don't think it fits the enterprise program, as there are many facilties but I'd like each faciltiy to be able to pay for the feature for individuals that work there. Asking for details I've missed or offering advice would be appreciated.
Posted Last updated
.
Post not yet marked as solved
9 Replies
2.5k Views
I need to exchange small amounts of data in my app near realtime between users who could be anywhere with only an internet connection. One user becomes a team leader and needs to send data (just a few bytes) to all other users on their team - up to 50 - about each second. Then each team member needs to send data (again, just a few bytes) back to the leader about each second. The requirement is similar to the example app from last year's WWDC networking part 2 video called TicTacToe, except the users may not be local. Is CloudKit a good fit for this requirement? I'd like to use it due to its easy integration with iOS apps, no need to setup or maintain a server environment and the way it deals with security. But I'm unclear as to whether CloudKit performance can deliver small records at that speed. Does anyone have a voice of experience using CloudKit for small, quick data exchanges? If not, is there another iOS framework I should consider? I've looked at GameKit but asking users to initiate a session in gamekit is a requirement I'd rather avoid. Thanks in advance for any guidance.
Posted Last updated
.
Post not yet marked as solved
0 Replies
774 Views
I see more music videos being included in the Apple Music catalog, and would like my users to be able to add them to their playlist in my app, but can't make it work.I'm able to get the audio to play by loading the music video's .playbackStoreID with setQueueWithStoreIDs:.But can't figure out any way to load AVPlayerViewController or an AVPlayer with a movie video from Apple Music in order to display the video in my app.Can anyone offer some guidance or direction?Thanks
Posted Last updated
.
Post not yet marked as solved
0 Replies
765 Views
I currently offer two in-app monthly subscription levels - "A &amp; B". Current prices are A = $2.99 &amp; B = $6.99 per month.These same levels used to be priced lower (A = $0.99 &amp; B = $4.99) and I have a number of users who subscribed at those prices and take advantage of the grandfathering option.If a level A subscriber who is grandfathered at $0.99 decides to do a trial of level B (I know this will be at $6.99 as it's a change in level) but then switches back to level A, will they still get the grandfathered renewal for level A of $0.99 or would their trial of another level remove their grandfathered pricing? Thanks in advance to anyone who can help with this!
Posted Last updated
.
Post not yet marked as solved
1 Replies
925 Views
I'm trying to create a CKShare on a set of CKRecords using CloudKit. I've made it through most of the workflow:create a 'root_record' that all shared records will identify as parentadd several records and identify 'root_record' as parentcreate CKShare on 'root_record' and present the share dialog with UICloudSharingControllerinclude mandatory itemTitleForCloudSharingController &amp; failedToSaveShareWithErrorinclude - (void)application:(UIApplication *)application userDidAcceptCloudKitShareWithMetadata: in appdelegate clicked backgroundmodes &gt; remote notification in capabilitiesI get the share dialog on device A, text or email the share to device B as expected. On device B, I get:Open "My_Title_String"? &gt; Not Now | OpenBut when I choose 'Open', I get:Update "App_Name"_sharer_ shared this. To open it, you'll need the latest version of "app_name". &gt; Got To App Store | Not NowI've tried upping the build number, deleting app + reinstalling &amp; installing from TestFlight, but - (void)application:(UIApplication *)application userDidAcceptCloudKitShareWithMetadata: never gets called on device B. Any advice on where I've gone wrong?
Posted Last updated
.