CloudKit Dashboard

RSS for tag

Monitor and manage the CloudKit database containers used by your apps.

Posts under CloudKit Dashboard tag

90 Posts

Post

Replies

Boosts

Views

Activity

CloudKit Subscriptions "Expected this response but could not parse it"
So I'm trying to create a new subscription based on a predicate. The predicate is if there is a new Record (of type Message) with conversationID to a given conversation ID. Okay so I've enabled notifications on my device and subscriptions do get sent to CloudKit. But then when I go onto the CloudKit dashboard I get this response: Error fetching subscriptions. Expected this response but could not parse it: HTTP 200, text: [{"subscriptions":[{"type":"query","subscriptionId":"CDF6D9BD-77E5-41C6-BC18-3AD1A49E1A7D","query":{"recordType":"Message","filters":{"fieldName":"conversationID","fieldValue":{"type":"stringType","value":"C8356727-83A0-4981-9C62-48B891B376EB"},"type":"EQUALS"}]},"firesOn":["CREATE"],"firesOnce":false,"zone":{"zoneName":"_zoneWide","canonicalName":"_zoneWide","ownerRecordName":"_df807ec5aa88995e336922b90835b528"}}]} So I'm confused about this. It seems like that is the response I was looking for, and I'm not sure why it can't query it. I remember seeing in another question something about there being an issue with a listEmpty or something. But I'm querying on a string so I don't understand why it's not working. my CloudKit code looks like this: func setNotifications(convoID: String) {     let database = CKContainer.default().publicCloudDatabase     let pred = NSPredicate(format: "conversationID == %@", convoID)     let newSubscription = CKQuerySubscription(recordType: RecordType.Message, predicate: pred, options: [.firesOnRecordCreation])     let notification = CKSubscription.NotificationInfo()     notification.alertBody = "You have a new message"     notification.shouldSendContentAvailable = true     newSubscription.notificationInfo = notification     database.save(newSubscription) { (subscription, error) in          if let error = error {               print(error)               return          }          if let _ = subscription {               print("Hurrah! We have a subscription")          }     } } Thanks!
7
0
1.2k
Sep ’21
CloudKit Dashboard goes blank when making a query
I have two Core Data entities synching with CloudKit nicely. When I query records for one in the Dashboard, the results are displayed as expected. However, when I query records for the other entity, the Dashboard goes black (completely, I mean, no navigation, etc.). I can confirm that changes to the records are synching across devices. I just can't figure out what is making the Dashboard query fail. Has anyone else encountered the same issue? Was there a solution? (BTW, I have made recordName queryable, since I've had that problem in the past. Also, my app is in development - not production.)
1
0
996
Aug ’21
Unable to populate value from CloudKit onto my display
Hello everyone! I am pretty new to SwiftUI and have been trying to figure out a solution to the issue below for about a week. I can successfully save values in CloudKit, and can load them within the operation.recordFetchedBlock block using print(String(ping.value)) on line 15. However, I can not figure out a way to actually load them on the display within ContentView: View For some reason I continue to get the following (empty array) in the output when using print(loadPing()) on line 9: [] No Error Found Below is the code: struct ContentView: View {     @StateObject var progress = UserProgress()     var body: some View{         VStack{             Button("Submit") {                 progress.ping += 1                 sendItem(counter: progress.ping)                 print(loadPing())             }             Text("Ping Count \(progress.ping)")         }     } } class Ping: NSObject {     let id = UUID()     var recordID: CKRecord.ID!     var name: String!     var value: String! } loadPing() -> [Ping]{     var newPing = [Ping]()     let ping = Ping()     let query = CKQuery(recordType: "PingTest", predicate: NSPredicate(value: true))     let operation = CKQueryOperation(query: query)     operation.desiredKeys = ["value", "name"]     operation.recordFetchedBlock = { record in         ping.recordID = record.recordID         ping.name = record["name"]         ping.value = record["value"]         newPing.append(ping) //        print(String(ping.value))     }     operation.queryCompletionBlock = {(cursor, error) in             DispatchQueue.main.async {                 if error == nil {                     print("No Error Found")                 } else {                     print("Error was Found")                     print(error!.localizedDescription)                 }             }         }      CKContainer.default().publicCloudDatabase.add(operation)     return newPing } I would be very grateful if someone could help me figure out a way to populate the actual values from CloudKit onto my display in the ContentView. I have sifted through various tutorials but nothing has worked so far.
3
0
1.2k
Jul ’21
(Swift + CloudKit) or (SwiftUi + Core Data + CloudKit)
Hello everyone! Im new to SwiftUI and I have been trying to pinpoint the best approach when sending and receiving data using CloudKit. Is Core Data absolutely necessary to use when building an app with SwiftUI and CloudKit? I've read that Core Data is falling off, which is why I'm questionable on spending time learning it. Couldn't I simply use SwiftUI and CloudKit without the use of anything else? I do know that Core Data is NOT necessary when using CloudKit while writing Objective C, but I am wanting to stick solely with Swift as I have been told that Obj C is falling off too. Thanks for the help!
3
0
1.6k
Jul ’21
Error fetching subscriptions on CloudKit Console
I'm unable to fetch Subscriptions in both the Development and Production environments in the new CloudKit Console. Just shows the following message; Error fetching subscriptions. There was a problem with your request. Please try again later. Has anyone else got this problem or know of a fix? I really don't want to have to reset the container and delete all of my testers data in the hopes that it might fix the problem.
2
0
1.1k
Jun ’21
CloudKit -No Containers
When I try to access the cloud database it says No Containers I have everything set up correctly. Everything in the pics below with the gray outline has the same exact identifier iCloud.com.myCo.myApp Entitlements: Xcode: developer.apple: I did a deep clean, closed Xcode, reopened it, deep clean again, build. Still No Containers. This is a paid account.
Replies
1
Boosts
0
Views
1.7k
Activity
Jan ’22
Telemetry charts missing
I am unable to preview any telemetry charts in the dashboard for a couple of weeks now. This happens for every member on our team and on any brower/device we try. Anyone else also experiencing this issue?
Replies
3
Boosts
0
Views
1.2k
Activity
Nov ’21
Can't enter date in Cloudkit Dashboard field
To create records in the Cloudkit Dashboard I was previously able to enter dates into a record field but now I can't. The dashboard won't accept any entries from the keyboard. I can enter all the other fields (text and double) but not a date. Why?
Replies
2
Boosts
0
Views
879
Activity
Oct ’21
CloudKit Subscriptions "Expected this response but could not parse it"
So I'm trying to create a new subscription based on a predicate. The predicate is if there is a new Record (of type Message) with conversationID to a given conversation ID. Okay so I've enabled notifications on my device and subscriptions do get sent to CloudKit. But then when I go onto the CloudKit dashboard I get this response: Error fetching subscriptions. Expected this response but could not parse it: HTTP 200, text: [{"subscriptions":[{"type":"query","subscriptionId":"CDF6D9BD-77E5-41C6-BC18-3AD1A49E1A7D","query":{"recordType":"Message","filters":{"fieldName":"conversationID","fieldValue":{"type":"stringType","value":"C8356727-83A0-4981-9C62-48B891B376EB"},"type":"EQUALS"}]},"firesOn":["CREATE"],"firesOnce":false,"zone":{"zoneName":"_zoneWide","canonicalName":"_zoneWide","ownerRecordName":"_df807ec5aa88995e336922b90835b528"}}]} So I'm confused about this. It seems like that is the response I was looking for, and I'm not sure why it can't query it. I remember seeing in another question something about there being an issue with a listEmpty or something. But I'm querying on a string so I don't understand why it's not working. my CloudKit code looks like this: func setNotifications(convoID: String) {     let database = CKContainer.default().publicCloudDatabase     let pred = NSPredicate(format: "conversationID == %@", convoID)     let newSubscription = CKQuerySubscription(recordType: RecordType.Message, predicate: pred, options: [.firesOnRecordCreation])     let notification = CKSubscription.NotificationInfo()     notification.alertBody = "You have a new message"     notification.shouldSendContentAvailable = true     newSubscription.notificationInfo = notification     database.save(newSubscription) { (subscription, error) in          if let error = error {               print(error)               return          }          if let _ = subscription {               print("Hurrah! We have a subscription")          }     } } Thanks!
Replies
7
Boosts
0
Views
1.2k
Activity
Sep ’21
CloudKit Dashboard goes blank when making a query
I have two Core Data entities synching with CloudKit nicely. When I query records for one in the Dashboard, the results are displayed as expected. However, when I query records for the other entity, the Dashboard goes black (completely, I mean, no navigation, etc.). I can confirm that changes to the records are synching across devices. I just can't figure out what is making the Dashboard query fail. Has anyone else encountered the same issue? Was there a solution? (BTW, I have made recordName queryable, since I've had that problem in the past. Also, my app is in development - not production.)
Replies
1
Boosts
0
Views
996
Activity
Aug ’21
Database lives in a different region. Please change your database URL to
When I want to run my app on the simulator, it shows this up. Where can I change it?
Replies
1
Boosts
0
Views
873
Activity
Jul ’21
Unable to populate value from CloudKit onto my display
Hello everyone! I am pretty new to SwiftUI and have been trying to figure out a solution to the issue below for about a week. I can successfully save values in CloudKit, and can load them within the operation.recordFetchedBlock block using print(String(ping.value)) on line 15. However, I can not figure out a way to actually load them on the display within ContentView: View For some reason I continue to get the following (empty array) in the output when using print(loadPing()) on line 9: [] No Error Found Below is the code: struct ContentView: View {     @StateObject var progress = UserProgress()     var body: some View{         VStack{             Button("Submit") {                 progress.ping += 1                 sendItem(counter: progress.ping)                 print(loadPing())             }             Text("Ping Count \(progress.ping)")         }     } } class Ping: NSObject {     let id = UUID()     var recordID: CKRecord.ID!     var name: String!     var value: String! } loadPing() -> [Ping]{     var newPing = [Ping]()     let ping = Ping()     let query = CKQuery(recordType: "PingTest", predicate: NSPredicate(value: true))     let operation = CKQueryOperation(query: query)     operation.desiredKeys = ["value", "name"]     operation.recordFetchedBlock = { record in         ping.recordID = record.recordID         ping.name = record["name"]         ping.value = record["value"]         newPing.append(ping) //        print(String(ping.value))     }     operation.queryCompletionBlock = {(cursor, error) in             DispatchQueue.main.async {                 if error == nil {                     print("No Error Found")                 } else {                     print("Error was Found")                     print(error!.localizedDescription)                 }             }         }      CKContainer.default().publicCloudDatabase.add(operation)     return newPing } I would be very grateful if someone could help me figure out a way to populate the actual values from CloudKit onto my display in the ContentView. I have sifted through various tutorials but nothing has worked so far.
Replies
3
Boosts
0
Views
1.2k
Activity
Jul ’21
When I fetch records on CloudKit Console, it fails
The error message is: Field 'recordName' is not marked queryable So I manually add the 'recordName' field on my Record Type and edit index to add 'recordName' as queryable. After my tweak, it stills shows me that error message. Could you guys tell me how to fix it? Thank you.
Replies
5
Boosts
0
Views
2.1k
Activity
Jul ’21
(Swift + CloudKit) or (SwiftUi + Core Data + CloudKit)
Hello everyone! Im new to SwiftUI and I have been trying to pinpoint the best approach when sending and receiving data using CloudKit. Is Core Data absolutely necessary to use when building an app with SwiftUI and CloudKit? I've read that Core Data is falling off, which is why I'm questionable on spending time learning it. Couldn't I simply use SwiftUI and CloudKit without the use of anything else? I do know that Core Data is NOT necessary when using CloudKit while writing Objective C, but I am wanting to stick solely with Swift as I have been told that Obj C is falling off too. Thanks for the help!
Replies
3
Boosts
0
Views
1.6k
Activity
Jul ’21
Error fetching subscriptions on CloudKit Console
I'm unable to fetch Subscriptions in both the Development and Production environments in the new CloudKit Console. Just shows the following message; Error fetching subscriptions. There was a problem with your request. Please try again later. Has anyone else got this problem or know of a fix? I really don't want to have to reset the container and delete all of my testers data in the hopes that it might fix the problem.
Replies
2
Boosts
0
Views
1.1k
Activity
Jun ’21