Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Selenium fails in Mavericks and iOS7 Simulator #169

Closed
jordi99 opened this issue Oct 24, 2013 · 17 comments
Closed

Selenium fails in Mavericks and iOS7 Simulator #169

jordi99 opened this issue Oct 24, 2013 · 17 comments

Comments

@jordi99
Copy link

jordi99 commented Oct 24, 2013

Yesterday we updated our development tools to test latest versions of Apple's software with our applications and now, tests are not working. :(
Can anyone help me?

Thanks.

{
  "class": "org.openqa.selenium.remote.Response",
  "hCode": 1813953336,
  "sessionId": null,
  "state": null,
  "status": 0,
  "value": {
    "build": {
      "revision": "120cf4311807e2e137e519f4c4877cf6340d0cbc",
      "time": "20130927-1435",
      "version": "0.6.5"
    },
    "ios": {"simulatorVersion": "7.0"},
    "java": {"version": "1.7.0_45"},
    "os": {
      "arch": "x86_64",
      "name": "Mac OS X",
      "version": "10.9"
    },
    "state": "success"
}

And the message from the server:

{"message":"cannot find command for GET, /\nBuild info: version: 'unknown', revision: 'unknown', time: 'unknown'\nSystem info: os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9', java.version: '1.7.0_45'\nDriver info: driver.version: unknown","screen":null,"class":"org.openqa.selenium.WebDriverException","stackTrace":    [{"fileName":"WebDriverLikeCommand.java","lineNumber":311,"className":"org.uiautomation.ios.communication.WebDriverLikeCommand","methodName":"getCommand"},{"fileName":"WebDriverLikeRequest.java","lineNumber":115,"className":"org.uiautomation.ios.communication.WebDriverLikeRequest","methodName":"getGenericCommand"},{"fileName":"WebDriverLikeRequest.java","lineNumber":119,"className":"org.uiautomation.ios.communication.WebDriverLikeRequest","methodName":"getVariableValue"},{"fileName":"WebDriverLikeRequest.java","lineNumber":132,"className":"org.uiautomation.ios.communication.WebDriverLikeRequest","methodName":"getSession"},{"fileName":"IOSServlet.java","lineNumber":150,"className":"org.uiautomation.ios.server.servlet.IOSServlet","methodName":"getResponse"},{"fileName":"IOSServlet.java","lineNumber":85,"className":"org.uiautomation.ios.server.servlet.IOSServlet","methodName":"process"},{"fileName":"IOSServlet.java","lineNumber":46,"className":"org.uiautomation.ios.server.servlet.IOSServlet","methodName":"doGet"},{"fileName":"HttpServlet.java","lineNumber":707,"className":"javax.servlet.http.HttpServlet","methodName":"service"},{"fileName":"HttpServlet.java","lineNumber":820,"className":"javax.servlet.http.HttpServlet","methodName":"service"},{"fileName":"ServletHolder.java","lineNumber":533,"className":"org.eclipse.jetty.servlet.ServletHolder","methodName":"handle"},{"fileName":"ServletHandler.java","lineNumber":475,"className":"org.eclipse.jetty.servlet.ServletHandler","methodName":"doHandle"},{"fileName":"SessionHandler.java","lineNumber":224,"className":"org.eclipse.jetty.server.session.SessionHandler","methodName":"doHandle"},{"fileName":"ContextHandler.java","lineNumber":920,"className":"org.eclipse.jetty.server.handler.ContextHandler","methodName":"doHandle"},{"fileName":"ServletHandler.java","lineNumber":403,"className":"org.eclipse.jetty.servlet.ServletHandler","methodName":"doScope"},{"fileName":"SessionHandler.java","lineNumber":184,"className":"org.eclipse.jetty.server.session.SessionHandler","methodName":"doScope"},{"fileName":"ContextHandler.java","lineNumber":856,"className":"org.eclipse.jetty.server.handler.ContextHandler","methodName":"doScope"},{"fileName":"ScopedHandler.java","lineNumber":117,"className":"org.eclipse.jetty.server.handler.ScopedHandler","methodName":"handle"},{"fileName":"HandlerList.java","lineNumber":47,"className":"org.eclipse.jetty.server.handler.HandlerList","methodName":"handle"},{"fileName":"HandlerWrapper.java","lineNumber":114,"className":"org.eclipse.jetty.server.handler.HandlerWrapper","methodName":"handle"},{"fileName":"Server.java","lineNumber":352,"className":"org.eclipse.jetty.server.Server","methodName":"handle"},{"fileName":"HttpConnection.java","lineNumber":596,"className":"org.eclipse.jetty.server.HttpConnection","methodName":"handleRequest"},{"fileName":"HttpConnection.java","lineNumber":1049,"className":"org.eclipse.jetty.server.HttpConnection$RequestHandler","methodName":"headerComplete"},{"fileName":"HttpParser.java","lineNumber":590,"className":"org.eclipse.jetty.http.HttpParser","methodName":"parseNext"},{"fileName":"HttpParser.java","lineNumber":212,"className":"org.eclipse.jetty.http.HttpParser","methodName":"parseAvailable"},{"fileName":"HttpConnection.java","lineNumber":426,"className":"org.eclipse.jetty.server.HttpConnection","methodName":"handle"},{"fileName":"SelectChannelEndPoint.java","lineNumber":510,"className":"org.eclipse.jetty.io.nio.SelectChannelEndPoint","methodName":"handle"},{"fileName":"SelectChannelEndPoint.java","lineNumber":34,"className":"org.eclipse.jetty.io.nio.SelectChannelEndPoint","methodName":"access$000"},{"fileName":"SelectChannelEndPoint.java","lineNumber":40,"className":"org.eclipse.jetty.io.nio.SelectChannelEndPoint$1","methodName":"run"},{"fileName":"QueuedThreadPool.java","lineNumber":450,"className":"org.eclipse.jetty.util.thread.QueuedThreadPool$2","methodName":"run"},{"fileName":"Thread.java","lineNumber":744,"className":"java.lang.Thread","methodName":"run"}]}
@nicegraham
Copy link
Member

have you tried the refactor branch?

@jordi99
Copy link
Author

jordi99 commented Oct 25, 2013

I have tried it just now. Build is success, but build tests are not. Also the outcome is the same as described when executing the server. Do I have to configure something to make build tests work or I'm doing something wrong?
Thanks for the help!

@nicegraham
Copy link
Member

can you make sure it's not the same problem as here:
#158 (comment)

@jordi99
Copy link
Author

jordi99 commented Oct 25, 2013

I deleted all the files in that folder and results different from before but not good:

That happens in during the tests in the build process:

53:48:973 WARNING IOSServlet.getResponse  58ms. DELETE   /session/:sessionId
org.openqa.selenium.WebDriverException: execution failed. Exit code =1 , command was: killall iPhone Simulator
Build info: version: '2.35.0', revision: '8df0c6bedf70ff9f22c647788f9fe9c8d22210e2', time: '2013-08-17 12:46:41'
System info: os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9', java.version: '1.7.0_45'
Driver info: driver.version: IOSDualDriver
at org.uiautomation.ios.utils.Command.executeAndWait(Command.java:67)
at org.uiautomation.ios.utils.Command.executeAndWait(Command.java:60)
at org.uiautomation.ios.utils.ClassicCommands.killall(ClassicCommands.java:78)
at org.uiautomation.ios.server.simulator.IOSSimulatorManager.cleanupDevice(IOSSimulatorManager.java:164)

After that, there is a popup which says "It cannot install the application inside the simulator". I have done the chmod command and perms are ok.

Once started the server, in address http://localhost:4444/wd/hub/, it shows:

  {"message":"cannot find command for GET, /\nBuild info: version:

Thanks for the quick reply!

@jasone
Copy link
Member

jasone commented Nov 19, 2013

I fixed a killall bug on the refactor branch. Please re-open if you continue to have issues.

@jasone jasone closed this as completed Nov 19, 2013
@basavaraj1985
Copy link

Where will I get the updated jar with fix to run on Mavericks? If should I take the refactor branch and build it myself, could somebody please give me the steps?

Issues am facing right now:
selenium automation is not able to run on iOS Simulator. I had OS X 10.8.5, it used to work fine. Now its not able to open the simulator.

What steps I have tried:
I tried to build the jar myself using refactor branch. I get following error:

$ mvn pom.xml [INFO] Scanning for projects... [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 0.069s [INFO] Finished at: Mon Nov 25 15:02:02 GMT+05:30 2013 [INFO] Final Memory: 2M/81M [INFO] ------------------------------------------------------------------------ [ERROR] The goal you specified requires a project to execute but there is no POM in this directory (/Users/basavar). Please verify you invoked Maven from the correct directory. -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MissingProjectException

Please help.

@nicegraham
Copy link
Member

it's a standard maven project. run mvn package in the root directory to build the artifacts.

@skyzyx
Copy link

skyzyx commented Jan 25, 2014

Did you remember to run git submodule update --init in the root of the git repository? I ran into the same issue earlier today.

@basavaraj1985
Copy link

@skyzyx , so are you able to run tests on mavericks ios simulator now? I dont see refactor branch anymore here. Could you give me the steps you followed?

@lukeis
Copy link
Member

lukeis commented Jan 25, 2014

the refactor branch has been merged back to the 'dev' branch, use that one now

@basavaraj1985
Copy link

when can we expect the downloadable jar release with the fix then? @skyzyx, if you have built the jar (ios-server-0.x.x-jar-with-dependencies.jar), could you please share it?

I tried downloading the dev branch as zip and building. And I get this error
http://pastebin.com/p31JXJNY

Note: I dont know maven. :(

@skyzyx
Copy link

skyzyx commented Jan 25, 2014

Here's what I'm running:


Initial stuff:

rm -rf ~/.ios-driver/ && \
sudo chmod 666 /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator*.sdk/Applications/MobileSafari.app/Info.plist && \
sudo chmod -R a+rw /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator*.sdk/Applications/MobileSafari.app && \
sudo chmod a+rw /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator*.sdk/Applications/

Install Maven from MacPorts

sudo port install maven3 && \
sudo port select --set maven maven3

Build ios-driver

git clone git@github.com:ios-driver/ios-driver.git && \
cd ios-driver && \
git checkout dev && \
git submodule update --init && \
mvn clean package

Start the server

java -jar server/target/ios-server-*-jar-with-dependencies.jar -simulators

@basavaraj1985
Copy link

@skyzyx , you are awesome! Thanks much for your time.

But still, am stuck at the same place, mvn clean package. :(

Here is what I get when I follow the exact steps you have given:
....
....
....
[INFO] --- maven-compiler-plugin:2.4:compile (default-compile) @ build ---
[INFO] Compiling 6 source files to /Users/basavar/.ssh/ios-driver/build/target/classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] Failure executing javac, but could not parse the error:
javac: invalid target release: 1.7
Usage: javac
use -help for a list of possible options

[INFO] 1 error
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] IOS automation .................................... SUCCESS [0.447s]
[INFO] build ............................................. FAILURE [0.367s]
[INFO] ios-common ........................................ SKIPPED
[INFO] ios-client ........................................ SKIPPED
[INFO] ios-server ........................................ SKIPPED
[INFO] ios-selenium-tests ................................ SKIPPED
[INFO] libimobiledevice-wrapper .......................... SKIPPED
[INFO] ios-grid .......................................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.968s
[INFO] Finished at: Sat Jan 25 18:13:02 GMT+05:30 2014
[INFO] Final Memory: 5M/81M
[INFO] ------------------------------------------------------------------------

And more info on my env:
$ javac -version
javac 1.7.0_40

$ java -version
java version "1.7.0_40"
Java(TM) SE Runtime Environment (build 1.7.0_40-b43)
Java HotSpot(TM) 64-Bit Server VM (build 24.0-b56, mixed mode)

$ xcodebuild -version
Xcode 5.0.2

Mac version: Mavericks 10.9

@majun8cn
Copy link

@basavaraj1985
I got the same issue.

It is because the JAVA_HOME is not taken properly by the mvn script. You can directly put the JAVA_HOME environment variable into the mvn script. It fixed my issue.

@QuantumGeordie
Copy link

when i run 'mvn clean package' i don't get the file server/target/ios-server-*-jar-with-dependencies.jar. instead i get...

server/target/ios-server-0.6.6-SNAPSHOT.jar
server/target/ios-server-standalone-0.6.6-SNAPSHOT-20140305-1032.jar

the standalone version does not know about the -simulator flag, but seems to be running with the simulator set to true. the other doesn't want to run (no main manifest attribute, in server/target/ios-server-0.6.6-SNAPSHOT.jar).

so i run the standalone jar and get this:

~/sandbox/ios-driver $ java -jar server/target/ios-server-standalone-0.6.6-SNAPSHOT-20140305-1032.jar                                                                                                                  
47:11:020 INFO ApplicationStore.<init>  App archive folder:/Users/geordie/sandbox/ios-driver/applications
47:11:874 INFO IOSServer.initDriver
Beta features enabled (enabled by -beta flag): false
Simulator enabled : true
Inspector: http://0.0.0.0:5555/inspector/
Tests can access the server at http://0.0.0.0:5555/wd/hub
Server status: http://0.0.0.0:5555/wd/hub/status
Connected devices: http://0.0.0.0:5555/wd/hub/devices/all
Applications: http://0.0.0.0:5555/wd/hub/applications/all
Capabilities: http://0.0.0.0:5555/wd/hub/capabilities/all
Monitoring '/Users/geordie/sandbox/ios-driver/applications' for new applications
Archived apps: /Users/geordie/sandbox/ios-driver/applications
Build info: ios-driver 0.6.6-SNAPSHOT (built:20140305-1032,sha:ad3258d1120e8a119a84aab239394240e5dd305b)
Running on: Mac OS X 10.9.2 (x86_64)
Using java: 1.7.0_45
Using Xcode install: /Applications/Xcode.app
Using instruments: version:5.0.1, build: 51168
Using iOS version 7.0.3
iOS >= 6.0. Safari and hybrid apps are supported.

Applications :
---------------
    CFBundleName=Safari,CFBundleVersion=9537.53,/Users/geordie/.ios-driver/safariCopies/safari-7.0.3.app

2014-03-05 13:47:11.954:INFO::jetty-7.x.y-SNAPSHOT
2014-03-05 13:47:12.042:INFO::Started SelectChannelConnector@0.0.0.0:5555

and then when i run the webdriver code here:

require "selenium-webdriver"

# driver = Selenium::WebDriver.for :firefox
driver = Selenium::WebDriver.for :remote, :url => "http://localhost:5555/wd/hub", :desired_capabilities => :ipad
driver.navigate.to "http://google.com"

element = driver.find_element(:name, 'q')
element.send_keys "Hello WebDriver!"
element.submit

puts driver.title

driver.quit

this happens in the driver terminal.

$ cp -rf /Users/geordie/.ios-driver/safariCopies/MobileSafari-7.0.3.app /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.0.sdk/Applications/MobileSafari.app
50:37:162 WARNING DefaultCommandListener.stderr  /var/folders/km/0vh9clxx1cl7r77m16ssz89h   2014-03-05 13:50:37.160 sim[32157:303] Multiple instances of launchd_sim detected, using com.apple.iphonesimulator.launchd.36cbc288 instead of com.apple.iphonesimulator.launchd.317e6565.
50:39:392 WARNING DefaultCommandListener.stderr  /var/folders/km/0vh9clxx1cl7r77m16ssz89h   2014-03-05 13:50:39.390 ScriptAgent[32157:3007] CLTilesManagerClient: initialize, sSharedTilesManagerClient
50:39:393 WARNING DefaultCommandListener.stderr  /var/folders/km/0vh9clxx1cl7r77m16ssz89h   2014-03-05 13:50:39.393 ScriptAgent[32157:3007] CLTilesManagerClient: init
50:39:393 WARNING DefaultCommandListener.stderr  /var/folders/km/0vh9clxx1cl7r77m16ssz89h   2014-03-05 13:50:39.393 ScriptAgent[32157:3007] CLTilesManagerClient: reconnecting, 0x993d8d0
50:40:225 WARNING DefaultCommandListener.stderr  /var/folders/km/0vh9clxx1cl7r77m16ssz89h   2014-03-05 13:50:40.225 ScriptAgent[32157:3007] AX Lookup problem! 1102 com.apple.iphone.axserver:32152
50:51:824 WARNING RemoteIOSWebDriver.<init>  session created but application size=0
java.lang.NullPointerException
    at org.uiautomation.ios.wkrdp.RemoteIOSWebDriver.get(RemoteIOSWebDriver.java:309)
    at org.uiautomation.ios.server.services.IOSDualDriver.start(IOSDualDriver.java:109)
    at org.uiautomation.ios.server.ServerSideSession.start(ServerSideSession.java:231)
    at org.uiautomation.ios.server.command.uiautomation.NewSessionNHandler.safeStart(NewSessionNHandler.java:82)
    at org.uiautomation.ios.server.command.uiautomation.NewSessionNHandler.handle(NewSessionNHandler.java:49)
    at org.uiautomation.ios.server.command.BaseCommandHandler.handleAndRunDecorators(BaseCommandHandler.java:104)
    at org.uiautomation.ios.server.servlet.IOSServlet.getResponse(IOSServlet.java:137)
    at org.uiautomation.ios.server.servlet.IOSServlet.process(IOSServlet.java:81)
    at org.uiautomation.ios.server.servlet.IOSServlet.doPost(IOSServlet.java:56)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:533)
    at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:475)
    at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:224)
    at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:920)
    at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:403)
    at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:184)
    at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:856)
    at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117)
    at org.eclipse.jetty.server.handler.HandlerList.handle(HandlerList.java:47)
    at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:114)
    at org.eclipse.jetty.server.Server.handle(Server.java:352)
    at org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:596)
    at org.eclipse.jetty.server.HttpConnection$RequestHandler.content(HttpConnection.java:1066)
    at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:805)
    at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:218)
    at org.eclipse.jetty.server.HttpConnection.handle(HttpConnection.java:426)
    at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:510)
    at org.eclipse.jetty.io.nio.SelectChannelEndPoint.access$000(SelectChannelEndPoint.java:34)
    at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:40)
    at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:450)
    at java.lang.Thread.run(Thread.java:744)

and this is the error from the script above...

[remote server] org.uiautomation.ios.server.command.uiautomation.NewSessionNHandler(NewSessionNHandler.java):72:in `handle': Build info: version: 'unknown', revision: 'unknown', time: 'unknown' (Selenium::WebDriver::Error::WebDriverError)
System info: os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9.2', java.version: '1.7.0_45'
Driver info: driver.version: unknown (org.openqa.selenium.SessionNotCreatedException)
    from [remote server] org.uiautomation.ios.server.command.BaseCommandHandler(BaseCommandHandler.java):104:in `handleAndRunDecorators'
    from [remote server] org.uiautomation.ios.server.servlet.IOSServlet(IOSServlet.java):137:in `getResponse'
    from [remote server] org.uiautomation.ios.server.servlet.IOSServlet(IOSServlet.java):81:in `process'
    from [remote server] org.uiautomation.ios.server.servlet.IOSServlet(IOSServlet.java):56:in `doPost'
    from [remote server] javax.servlet.http.HttpServlet(HttpServlet.java):727:in `service'
    from [remote server] javax.servlet.http.HttpServlet(HttpServlet.java):820:in `service'
    from [remote server] org.eclipse.jetty.servlet.ServletHolder(ServletHolder.java):533:in `handle'
    from [remote server] org.eclipse.jetty.servlet.ServletHandler(ServletHandler.java):475:in `doHandle'
    from [remote server] org.eclipse.jetty.server.session.SessionHandler(SessionHandler.java):224:in `doHandle'
    from [remote server] org.eclipse.jetty.server.handler.ContextHandler(ContextHandler.java):920:in `doHandle'
    from [remote server] org.eclipse.jetty.servlet.ServletHandler(ServletHandler.java):403:in `doScope'
    from [remote server] org.eclipse.jetty.server.session.SessionHandler(SessionHandler.java):184:in `doScope'
    from [remote server] org.eclipse.jetty.server.handler.ContextHandler(ContextHandler.java):856:in `doScope'
    from [remote server] org.eclipse.jetty.server.handler.ScopedHandler(ScopedHandler.java):117:in `handle'
    from [remote server] org.eclipse.jetty.server.handler.HandlerList(HandlerList.java):47:in `handle'
    from [remote server] org.eclipse.jetty.server.handler.HandlerWrapper(HandlerWrapper.java):114:in `handle'
    from [remote server] org.eclipse.jetty.server.Server(Server.java):352:in `handle'
    from [remote server] org.eclipse.jetty.server.HttpConnection(HttpConnection.java):596:in `handleRequest'
    from [remote server] org.eclipse.jetty.server.HttpConnection$RequestHandler(HttpConnection.java):1066:in `content'
    from [remote server] org.eclipse.jetty.http.HttpParser(HttpParser.java):805:in `parseNext'
    from [remote server] org.eclipse.jetty.http.HttpParser(HttpParser.java):218:in `parseAvailable'
    from [remote server] org.eclipse.jetty.server.HttpConnection(HttpConnection.java):426:in `handle'
    from [remote server] org.eclipse.jetty.io.nio.SelectChannelEndPoint(SelectChannelEndPoint.java):510:in `handle'
    from [remote server] org.eclipse.jetty.io.nio.SelectChannelEndPoint(SelectChannelEndPoint.java):34:in `access$000'
    from [remote server] org.eclipse.jetty.io.nio.SelectChannelEndPoint$1(SelectChannelEndPoint.java):40:in `run'
    from [remote server] org.eclipse.jetty.util.thread.QueuedThreadPool$2(QueuedThreadPool.java):450:in `run'
    from [remote server] java.lang.Thread(Thread.java):744:in `run'
    from /Users/geordie/.rvm/gems/ruby-2.0.0-p353/gems/selenium-webdriver-2.39.0/lib/selenium/webdriver/remote/response.rb:51:in `assert_ok'
    from /Users/geordie/.rvm/gems/ruby-2.0.0-p353/gems/selenium-webdriver-2.39.0/lib/selenium/webdriver/remote/response.rb:15:in `initialize'
    from /Users/geordie/.rvm/gems/ruby-2.0.0-p353/gems/selenium-webdriver-2.39.0/lib/selenium/webdriver/remote/http/common.rb:59:in `new'
    from /Users/geordie/.rvm/gems/ruby-2.0.0-p353/gems/selenium-webdriver-2.39.0/lib/selenium/webdriver/remote/http/common.rb:59:in `create_response'
    from /Users/geordie/.rvm/gems/ruby-2.0.0-p353/gems/selenium-webdriver-2.39.0/lib/selenium/webdriver/remote/http/default.rb:66:in `request'
    from /Users/geordie/.rvm/gems/ruby-2.0.0-p353/gems/selenium-webdriver-2.39.0/lib/selenium/webdriver/remote/http/common.rb:40:in `call'
    from /Users/geordie/.rvm/gems/ruby-2.0.0-p353/gems/selenium-webdriver-2.39.0/lib/selenium/webdriver/remote/bridge.rb:634:in `raw_execute'
    from /Users/geordie/.rvm/gems/ruby-2.0.0-p353/gems/selenium-webdriver-2.39.0/lib/selenium/webdriver/remote/bridge.rb:99:in `create_session'
    from /Users/geordie/.rvm/gems/ruby-2.0.0-p353/gems/selenium-webdriver-2.39.0/lib/selenium/webdriver/remote/bridge.rb:68:in `initialize'
    from /Users/geordie/.rvm/gems/ruby-2.0.0-p353/gems/selenium-webdriver-2.39.0/lib/selenium/webdriver/common/driver.rb:33:in `new'
    from /Users/geordie/.rvm/gems/ruby-2.0.0-p353/gems/selenium-webdriver-2.39.0/lib/selenium/webdriver/common/driver.rb:33:in `for'
    from /Users/geordie/.rvm/gems/ruby-2.0.0-p353/gems/selenium-webdriver-2.39.0/lib/selenium/webdriver.rb:67:in `for'

any help would be appreciated.

@basavaraj1985
Copy link

@QuantumGeordie, same observations till running my web driver code. Once i run my webdriver code, I see this on console:

2014-03-07 12:15:56.060:INFO::jetty-7.x.y-SNAPSHOT 2014-03-07 12:15:56.147:INFO::Started SelectChannelConnector@0.0.0.0:5555 20:22:285 INFO InstrumentsApple.moveMobileSafariAppOutOfInstallDir temporarily moving MobileSafari out of the install directory, if you need to restore it yourself use: $ cp -rf /Users/basavar/.ios-driver/safariCopies/MobileSafari-7.0.3.app /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.0.sdk/Applications/MobileSafari.app org.openqa.selenium.WebDriverException: iPhone variation incompatible with SDK 7.0.3, a compatible variation is Retina4 Build info: version: 'unknown', revision: 'unknown', time: 'unknown' System info: os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9', java.version: '1.7.0_40' Driver info: driver.version: IOSDualDriver at org.uiautomation.ios.utils.SimulatorSettings.getSimulateDeviceValue(SimulatorSettings.java:254) at org.uiautomation.ios.utils.SimulatorSettings.setVariation(SimulatorSettings.java:166) at org.uiautomation.ios.server.simulator.IOSSimulatorManager.setVariation(IOSSimulatorManager.java:194) at org.uiautomation.ios.server.simulator.InstrumentsApple.start(InstrumentsApple.java:123) at org.uiautomation.ios.server.InstrumentsBackedNativeIOSDriver.start(InstrumentsBackedNativeIOSDriver.java:44) at org.uiautomation.ios.server.services.IOSDualDriver.start(IOSDualDriver.java:105) at org.uiautomation.ios.server.ServerSideSession.start(ServerSideSession.java:231) at org.uiautomation.ios.server.command.uiautomation.NewSessionNHandler.safeStart(NewSessionNHandler.java:82) at org.uiautomation.ios.server.command.uiautomation.NewSessionNHandler.handle(NewSessionNHandler.java:49) at org.uiautomation.ios.server.command.BaseCommandHandler.handleAndRunDecorators(BaseCommandHandler.java:104) at org.uiautomation.ios.server.servlet.IOSServlet.getResponse(IOSServlet.java:137) at org.uiautomation.ios.server.servlet.IOSServlet.process(IOSServlet.java:81) at org.uiautomation.ios.server.servlet.IOSServlet.doPost(IOSServlet.java:56) at javax.servlet.http.HttpServlet.service(HttpServlet.java:727) at javax.servlet.http.HttpServlet.service(HttpServlet.java:820) at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:533) at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:475) at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:224) at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:920) at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:403) at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:184) at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:856) at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117) at org.eclipse.jetty.server.handler.HandlerList.handle(HandlerList.java:47) at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:114) at org.eclipse.jetty.server.Server.handle(Server.java:352) at org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:596) at org.eclipse.jetty.server.HttpConnection$RequestHandler.content(HttpConnection.java:1066) at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:805) at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:218) at org.eclipse.jetty.server.HttpConnection.handle(HttpConnection.java:426) at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:510) at org.eclipse.jetty.io.nio.SelectChannelEndPoint.access$000(SelectChannelEndPoint.java:34) at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:40) at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:450) at java.lang.Thread.run(Thread.java:724)

@spatchamatla01
Copy link

when i run:
DesiredCapabilities safari = IOSCapabilities.iphone("Safari");
RemoteWebDriver driver = new RemoteWebDriver(new URL("http://localhost:5555/wd/hub"), safari);

i see the issue::

Exception in thread "main" org.openqa.selenium.SessionNotCreatedException: {simulator=true, timeHack=false, locale=en_GB, CFBundleName=Safari, device=iphone, language=en} no devices available.
Known devices: [Simulator[busy]]
Build info: version: 'unknown', revision: 'unknown', time: 'unknown'
System info: os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9.2', java.version: '1.7.0_51'
Driver info: driver.version: unknown
Build info: version: 'unknown', revision: 'unknown', time: 'unknown'
System info: os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9.2', java.version: '1.7.0_51'
Driver info: driver.version: unknown
Command duration or timeout: 164 milliseconds
Build info: version: '2.40.0', revision: 'fbe29a9', time: '2014-02-19 20:55:11'
System info: host: 'atl-mbp-mac33.local', ip: '10.29.1.164', os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9.2', java.version: '1.7.0_51'
Driver info: org.openqa.selenium.remote.RemoteWebDriver
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:193)
at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:145)
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:573)
at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:218)
at org.openqa.selenium.remote.RemoteWebDriver.(RemoteWebDriver.java:113)
at org.openqa.selenium.remote.RemoteWebDriver.(RemoteWebDriver.java:131)
at com.sruja.testIOS.iosSim.main(iosSim.java:16)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:120)
Caused by: org.openqa.selenium.SessionNotCreatedException: {simulator=true, timeHack=false, locale=en_GB, CFBundleName=Safari, device=iphone, language=en} no devices available.
Known devices: [Simulator[busy]]
Build info: version: 'unknown', revision: 'unknown', time: 'unknown'
System info: os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9.2', java.version: '1.7.0_51'
Driver info: driver.version: unknown
Build info: version: 'unknown', revision: 'unknown', time: 'unknown'
System info: os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9.2', java.version: '1.7.0_51'
Driver info: driver.version: unknown
Build info: version: '2.40.0', revision: 'fbe29a9', time: '2014-02-19 20:55:11'
System info: host: 'atl-mbp-mac33.local', ip: '10.29.1.164', os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9.2', java.version: '1.7.0_51'
Driver info: driver.version: unknown
at org.uiautomation.ios.server.command.uiautomation.NewSessionNHandler.handle(NewSessionNHandler.java:73)
at org.uiautomation.ios.server.command.BaseCommandHandler.handleAndRunDecorators(BaseCommandHandler.java:104)
at org.uiautomation.ios.server.servlet.IOSServlet.getResponse(IOSServlet.java:137)
at org.uiautomation.ios.server.servlet.IOSServlet.process(IOSServlet.java:81)
at org.uiautomation.ios.server.servlet.IOSServlet.doPost(IOSServlet.java:56)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:533)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:475)
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:224)
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:920)
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:403)
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:184)
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:856)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117)
at org.eclipse.jetty.server.handler.HandlerList.handle(HandlerList.java:47)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:114)
at org.eclipse.jetty.server.Server.handle(Server.java:352)
at org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:596)
at org.eclipse.jetty.server.HttpConnection$RequestHandler.content(HttpConnection.java:1066)
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:805)
at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:218)
at org.eclipse.jetty.server.HttpConnection.handle(HttpConnection.java:426)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:510)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint.access$000(SelectChannelEndPoint.java:34)
at org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:40)
at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:450)
at java.lang.Thread.run(Thread.java:744)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants