Livecode revdberr invalid database connection - ios

The simulator and the actual iPhone are giving me this error when trying to make the connection to the database.
revdberr invalid database type
My database is the mysql service that comes with the livecode hosting.
I can run the app fine from my Mac and from my PC, but simulator and phone gives the error.
I have checked the Mysql external under standalone application settings.
The line of code I am using is
put revOpenDatabase("MySQL", tDatabaseAddress, tDatabaseName, tDatabaseUser, tDatabasePassword) into tResult
My LC version is 7.1.0 Indy and Xcode 6.4
Another thing to note is that it gives me the error while disconnected from the internet also, so something is happening before even trying to connect.
Going crazy here :)

Related

Swift Realm - ATS failed system trust

I am upgrading a project from Swift 3 to Swift 5. The project uses Realm for an internal database, but every time I launch the app in the simulator I get the following errors in the console:
ATS failed system trust
Connection 2: system TLS Trust evaluation failed(-9802)
I'm pretty sure this is a Realm issue as the app doesn't try to make any other external connections. When running on a older version of Xcode(8), it all works fine without errors. I'm currently testing on Xcode 10.3 and 11 (beta) and using Realm 3.17.3.
Any help would be appreciated.
This error is only produced in the simulator. When running on an actual device no errors get logged

iOS app cannot connect to MobileFirst server

i created an hybrid application that should connect to the MFP and consume data.
When i try to connect to the Desktop Browser Application everything is fine and the app works. Same behaviour when i try the Mobile Web Application. BUT when i try to connect with the mobile native iOS application i could not connect and receive the following error (in the console):
2015-11-12 17:22:15.031 APPXYZ[6072:3089110] [FATAL] [NONE] Uncaught Exception: TypeError: WLJSX.Ajax.WLRequest.setConnected is not a function. (In 'WLJSX.Ajax.WLRequest.setConnected(false)', 'WLJSX.Ajax.WLRequest.setConnected' is undefined) at (compiled_code):3871
My specs:
MFP version 7.1.0.00.20151107-1653
Xcode 7.1.1
iOS deploy target 8.0
Transport security protocol is deactivated (Allow Arbitrary Loads -> YES)
I cannot confirm this claim.
Using the following, I create a blank new Hybrid app with the iPhone environment, that calls the WL.Client.connect method in wlCommonInit() and displays an alert with "success" or "failure" accordingly. I got "success". No errors in the Xcode Console.
Xcode 7.1.1
IBM MobileFirst Platform Studio 7.1.0.00-20151107-1647
If you are doing something different in your project, do let us know...
The solution of my problem was that i change the init calling sequence of my app. I called the wl specific functions to early. After changing the sequence my app runs perfectly.....
thx 4 help :)

Calabash testing on iOS device starts app but freezes on "Scenario"

I have been trying to use Calabash to test some simple iOS apps. I was able to run the app on the simulator and all steps work fine. Now I want to test it on an iOS device, but I am having some problems. I run this command with all the necessary info:
BUNDLE_ID=... DEVICE_TARGET=... DEVICE_ENDPOINT=http://MY_IP:37265 cucumber
After a while the app opens in the iPhone and I get the usual information on console:
Feature: Running a test
As an iOS developer
I want to have a sample feature file
So I can begin testing quickly
Scenario: Example steps # features/my_first.feature:6
But it stays there forever. I left it for a while and it does nothing.
I have tried Appium, as well, for testing and it worked fine both on the simulator and on the iPhone, so I guess is not a problem with Profiles and the device itself.
What could be causing this issue?
My setup:
- Mac OS X 10.10.3
- Xcode Version 6.3 (6D570)
- iPhone 4 - iOS 7.1.2 (11D257)
- calabash-cucumber (0.14.0)
- cucumber (1.3.19)
UPDATE
Trying curl http://192.168.200.168:37265/version (as suggested by #alannichols) I get:
Failed to connect to 192.168.200.168 port 37265: Operation timed out
But I got my test to move to the first step executing the -cal target from Xcode (on the device) and running the command:
NO_LAUNCH=1 DEVICE_TARGET=... DEVICE_ENDPOINT=http://192.168.200.168:37265 cucumber
Still I am getting an error, but this time is a timeout error:
Operation timed out - connect(2) for "192.168.200.168" port 37265 (Errno::ETIMEDOUT)
Does it mean that I am reaching the iPhone by somehow I am not able to send requests?
If the app opens and nothing happens, it's usually to do with the device endpoint setting being incorrect. The app opens based on the bundle ID, but then calabash tries to interact with the app via the device endpoint.
Try running the app in the calabash console and if it behaves the same way as in your tests it'll be an issue with the device endpoint. Some ideas of things to check are that you're on the same network on the phone and the machine the test is running on, whether your vpn is interfering with the communication somehow or whether instruments is open on the test machine.
When the app is open you should be able to run
curl http://your.ip.address:37265/version
and get a response with the version number of calabash. If you can't get that then calabash won't be able to do anything in your tests.

WL.Client.login() then nsurlerrordomain error 1012

Worklight 6.2 building a hybrid application targeting iPad - we get the symptoms described below in the xCode Simulator irrespective of exactly which target device we select.
The application currently attempts a call to
WL.Client.login()
from within wlCommoninit()
Our target server is a full WL Server running on a Liberty instance on a remote machine, we use HTTPS and a specified IP Address
https://w.x.y.z:443/worklight
We have adjusted the Deploy Target and rebuilt the app before running XCode.
The WL.Client.login() error callback fires and we see log messages indicating that we are attempting to hit the correct URL. We also see this error message
NSURLErrorDomain error -1012
We do have a complex network setup, with a firewall between the iOS simulator and the server and yet if we run up Safari on the simulated device we can correctly access the URL.
Questions:
Does that NSURLErrorDomain reflect the cause of the failure? Or is it just part of the error processing?
Any suggestions for further diagnosis?
Further investigation indicated that we did have the wrong URL configured. It seems that
NSURLErrorDomain error -1012
is not in itself an indicator of the problem. Rather, the error follows from the failure to reach the specified host. Conclusion: study the logs prior top that NSURLErrorDomain message.

IBM Worklight 6.1 - Adapter invocation failing in iOS 5 after upgrading to v6.1

We have developed a Worklight-based Hybrid application with Native pages as well. Our start page is a native page from which we are invoking an adapter.
After upgrading to Worklight 6.1, this adapter invocation is now always failing in iOS 5, however continues to function correctly in iOS 6 and iOS 7.
When the adapter invocation fails, it returns raw HTML as the response: Adapter Failure Response.
In Xcode Console this is the error we see:
[ERROR] Worklight: -[WLRequest requestFailed:]:338::Status code='404'
error='(null)' [ERROR] Worklight: -[WLClient
onInvokeProcedureFailure:userInfo:]:696::response string=HTML
returning from adapter
The same application in Worklight 6.0.0.x works OK in iOS 5, 6 and 7.
This sample application can be used to see the error.
From tests made, it appears that the adapter invocation fails only in iOS 5 because the request sent contains double-slashes whereas in iOS 6 and 7 it contains one slash.
This can be verified in Wireshark:
This is a defect
There is not applicable workaround
Once the defect is fixed, it will be available via IBM Fix Central, as well as in the PMR that your customer needs to open anyway to get this fixed.
Check your wlclient.properties file, especially wlServerContext property. Looks like you're trying to connect to invalid URL.

Resources