SDK: 3.x
App ID: 3562E910-193E-F469-FFA8-DF25DFDCA000
Version ID: v1_dev
We had duplicated a version so that we could have a production and development stage. After duplicating the initial version started giving FAULT = ‘1900’ [Entity is missing or null] error when we pull data. We didn’t even changed anything in either version. Luckily it was our development version so we decided to delete it and see if we could start new (hence the recent topic post of a bug that wouldn’t let me delete it). Once the old development version was deleted, we recreated our db schema. The error still persist when we try to pull anything. What could be the different causes of this error?
Does it happen for every table? Just in that version or both of them?
No not every table, just Person and the version is just v1_dev.
I just tried a REST request and was able to get the data without any problem. Here’s a curl command:
curl -X GET -H 'application-id:3562E910-193E-F469-FFA8-DF25DFDCA000' \
-H 'secret-key:YOUR-REST-SECRET-KEY' \
http://api.backendless.com/v1_dev/data/Person
Does it fail with Android/iOS for you?
I tried a REST request as well and it worked but on the iOS side it fails.
Just to make sure, did you pass “v1_dev” into the “initApp” call?
Sure do
#if DEV
backendless?.initApp(APP_ID, secret:SECRET_KEY, version:VERSION_NUM_DEV) // dev
#else
backendless?.initApp(APP_ID, secret:SECRET_KEY, version:VERSION_NUM_PROD) // prod
#endif
And I double checked that it is using the dev version
So here’s an update: nothing seemed to work by creating a new version so I deployed v1_prod to v1_dev.
It was looking like we were getting somewhere until all business logic times out right away.
Error: FAULT = ‘15000’ [Custom business logic execution has been terminated because it did not complete in permitted time - 5 seconds]
AND
A simple query gives an NSDictionary instead of an array of the model objects.
let dataQuery = BackendlessDataQuery()
dataQuery.queryOptions.sortBy = ["created DESC"]
dataStore?.find(dataQuery, response: { (result) in
let groups = result?.getCurrentPage() as! [Group] // ERROR HERE
completionHandler(groups)
}, error: { (fault) in
print("Server reported an error: \(String(describing: fault))")
})
Error: Could not cast value of type ‘__NSDictionaryM’ (0x1b8078c50) to ‘App_Name.Group’ (0x100377a98).
-
Now for some reason it works in debug. But we are still back to the original post error. So yes, it does work in debug mode and executes within 5 seconds and it does handle Promises.
-
Yes it does have the proper values for the tables but some reason it stays as an NSDictionary instead of parsing to the model like it was doing before.
For both scenarios,There have been no changes except deploying to a different version.
Is the Business Logic issue resolved yet?
Also please provide the full sample code with a data find request in iOS SDK which fails on one of the versions, so that we could try to reproduce that.