Error running Protractor : "Error while running testForAngular: Unable to communicate to node"
Opened this issue · 1 comments
firstor commented
I got the error while running Protractor tests on the BrowserStack.
warning From Yarn 1.0 onwards, scripts don't require "--" for options to be forwarded. In a future version, any explicit "--" will be forwarded as-is to the scripts.
$ tsc -p e2e/tsconfig.e2e.json && protractor e2e/build/protractor.config.js
[06:26:44] W/driverProviders - Using driver provider hosted, but also found extra driver provider parameter(s): browserstackUser, browserstackKey
[06:26:44] I/launcher - Running 1 instances of WebDriver
[06:26:44] I/hosted - Using the selenium server at http://hub-cloud.browserstack.com/wd/hub
[06:27:00] W/runner - Ignoring unknown extra flags: target. This will be an error in future versions, please use --disableChecks flag to disable the Protractor CLI flag checks.
...
Error: Error while running testForAngular: Unable to communicate to node
at executeAsyncScript_.then (/home/workspace/project/node_modules/protractor/lib/browser.ts:945:27)
at ManagedPromise.invokeCallback_ (/home/workspace/project/node_modules/selenium-webdriver/lib/promise.js:1366:14)
at TaskQueue.execute_ (/home/workspace/project/node_modules/selenium-webdriver/lib/promise.js:2970:14)
at TaskQueue.executeNext_ (/home/workspace/project/node_modules/selenium-webdriver/lib/promise.js:2953:27)
at asyncRun (/home/workspace/project/node_modules/selenium-webdriver/lib/promise.js:2813:27)
at /home/workspace/project/node_modules/selenium-webdriver/lib/promise.js:676:7
at process._tickCallback (internal/process/next_tick.js:109:7)
[ERROR] Error: Error: Error while running testForAngular: Unable to communicate to node
at /home/workspace/project/e2e/build/specs/home.spec.js:17:19
at process._tickCallback (internal/process/next_tick.js:109:7)
[05:43:16] E/launcher - Process exited with error code 1
- Protractor: v5.1.2
- Protractor configuration:
seleniumAddress: 'http://hub-cloud.browserstack.com/wd/hub', baseUrl: 'http://localhost:5001', ... capabilities: { 'name': 'Safari on iPhone', 'device': 'iPhone 7 Plus', 'realMobile': 'true', 'os': 'ios', 'os_version': '10.3', 'browserName': 'iPhone', 'browserstack.local': true, 'browserstack.debug': true }
Could you help me solve the issue?
ashwingonsalves commented
I understand you are seeing the failure only while testing on iOS devices.
Protractor injects JavaScripts using execute_async method. The execute_async method is not fully supported by Appium. Thus, you may not receive a valid response. This probably results in the failures you are seeing while testing on iOS devices.
At the moment, there is no workaround to the issue unless fixed in Appium.