title: Appium could not start a new session
body: <p>I'm trying to launch my app from Android app in my mac using Appium.app<br>
  or using my code but I'm getting an error as </p>
  
  <p>Could not start a new session.</p>
  
  <p>Be sure the Appium server is running with an application opened by<br>
  using the "App Path" parameter in Appium.app (along with package and<br>
  activity for Android) or by connecting with selenium client and<br>
  supplying this in the desired capabilities object."</p>
  
  <pre><code>Launching Appium with command: export     
  ANDROID_HOME="/Users/user1/Library/Android/sdk/"; 
  '/Applications/Appium.app/Contents/Resources/node/bin/node'             
  appium/build/lib/main.js --port "4724" --session-override --debug-log-    
  spacing --automation-name "Appium" --platform-name "Android" --
  platform-version "4.4" --app     "/Users/user1/WorkSpace/Automation/automation/automation_tests/selenium/src    /test/resources/myApp.apk" --full-reset --dont-stop-app-on-reset --avd     
  "10_1_WXGA_Tablet_API_24" --app-pkg "com.myApp.com" --app-activity     
  "com.myApp.com.activities.MainActivity" --app-wait-package     
  "com.myApp.com" --app-wait-activity 
  "com.myApp.com.activities.AndroidDatabaseManager" --device-name 
  "10_1_WXGA_Tablet_API_24" --language "en" --intent-action     
  "android.intent.action.MAIN" --intent-category 
  "android.intent.category.LAUNCHER"
  
  [Appium] Welcome to Appium v1.5.3
  
  [Appium] Non-default server args:
  
  [Appium]   port: 4724
  [Appium]   sessionOverride: true
  [Appium]   debugLogSpacing: true
  [Appium]   platformName: 'Android'
  [Appium]   platformVersion: '4.4'
  
  [Appium]   automationName: 'Appium'
  [Appium]   deviceName: '10_1_WXGA_Tablet_API_24'
  [Appium]   app:     
  '/Users/user1/WorkSpace/Automation/automation/automation_tests/selenium/src
  /test/resources/MyApp.apk’
  [Appium]   language: 'en'
  [Appium]   fullReset: true
  [Appium]   appPackage: 'com.myapp.com’
  [Appium]   appActivity: 'com.myapp.MainActivity'
  [Appium]   appWaitPackage: 'com.myApp.com'
  [Appium]   appWaitActivity: 
  'com.myApp.com.activities.AndroidDatabaseManager'
  [Appium]   avd: '10_1_WXGA_Tablet_API_24'
  [Appium]   dontStopAppOnReset: true
  [Appium] Deprecated server args:
  [Appium]   --platform-name =&gt; --default-capabilities     
  '{"platformName":"Android"}'
  [Appium]   --platform-version =&gt; --default-capabilities     
  '{"platformVersion":"4.4"}'
  [Appium]   --automation-name =&gt; --default-capabilities 
  '{"automationName":"Appium"}'
  [Appium]   --device-name =&gt; --default-capabilities     
  '{"deviceName":"10_1_WXGA_Tablet_API_24"}'
  [Appium]   --app =&gt; --default-capabilities     
  '{"app":"/Users/user1/WorkSpace/Automation/automation/_automation_tests/sel    enium/src/test/resources/myApp.apk"}'
  [Appium]   --language =&gt; --default-capabilities '{"language":"en"}'
  
  [Appium]   --full-reset =&gt; --default-capabilities '{"fullReset":true}'
  [Appium]   --app-pkg =&gt; --default-capabilities     
  '{"appPackage":"com.myApp.com"}'
  [Appium]   --app-activity =&gt; --default-capabilities     
  '{"appActivity":"com.myApp.com.activities.MainActivity"}'
  [Appium]   --app-wait-package =&gt; --default-capabilities 
  '{"appWaitPackage":"com.myApp.com"}'
  [Appium]   --app-wait-activity =&gt; --default-capabilities     
  '{"appWaitActivity":"com.myApp.com.activities.AndroidDatabaseManager"}'
  [Appium]   --avd =&gt; --default-capabilities     
  '{"avd":"10_1_WXGA_Tablet_API_24"}'
  [Appium]   --dont-stop-app-on-reset =&gt; --default-capabilities     
  '{"dontStopAppOnReset":true}'
  [Appium] Default capabilities, which will be added to each request     
  unless overridden by desired capabilities:
  
  [Appium]   platformName: 'Android'
  
  [Appium]   platformVersion: '4.4'
  [Appium]   automationName: 'Appium'
  [Appium]   deviceName: '10_1_WXGA_Tablet_API_24'
  [Appium]   app: 
  '/Users/user1/WorkSpace/Automation/automation/automation_tests/selenium/src
  /test/resources/myApp.apk'
  [Appium]   language: 'en'
  [Appium]   fullReset: true
  [Appium]   appPackage: 'com.myApp.com'
  [Appium]   appActivity: 'com.myApp.com.activities.MainActivity'
  [Appium]   appWaitPackage: 'com.myApp.com'
  [Appium]   appWaitActivity: 
  'com.myApp.com.activities.AndroidDatabaseManager'
  [Appium]   avd: '10_1_WXGA_Tablet_API_24'
  [Appium]   dontStopAppOnReset: true
  
  [Appium] Appium REST http interface listener started on 0.0.0.0:4724
  
  [HTTP] --&gt; GET /wd/hub/status {}
  
  [MJSONWP] Calling AppiumDriver.getStatus() with args: []
  
  
  
  
  
  [debug] [ADB] Device API level: 24
  
  [debug] [ADB] Getting connected devices...
  
  [debug] [ADB] 1 device(s) connected
  [debug] [ADB] Running /Users/user1/Library/Android/sdk/platform-
  tools/adb with args: ["-P",5037,"-s","emulator-
  5554","shell","getprop","persist.sys.locale"]
  [debug] [ADB] Current device property 'persist.sys.locale': 
  [debug] [ADB] Getting connected devices...
  
  [debug] [ADB] 1 device(s) connected
  [debug] [ADB] Running /Users/user1/Library/Android/sdk/platform-
  tools/adb with args: ["-P",5037,"-s","emulator-
  5554","shell","getprop","ro.product.locale"]
  
  [HTTP] &lt;-- GET /wd/hub/status - - ms - - 
  
  [debug] [ADB] Current device property 'ro.product.locale': en-US
  
  [debug] [ADB] Setting device property 'persist.sys.locale' to 'en'
  [debug] [ADB] Getting connected devices...
  [debug] [ADB] 1 device(s) connected
  [debug] [ADB] Running /Users/user1/Library/Android/sdk/platform-
  tools/adb with args: ["-P",5037,"-s","emulator-
  5554","shell","setprop","persist.sys.locale","en"]
  
  [debug] [ADB] Getting connected devices...
  
  [debug] [ADB] 1 device(s) connected
  [debug] [ADB] Running /Users/user1/Library/Android/sdk/platform-
  tools/adb with args: ["-P",5037,"-s","emulator-5554","shell","stop"]
  
  [debug] [ADB] Running /Users/user1/Library/Android/sdk/platform-
  tools/adb with args: ["-P",5037,"-s","emulator-5554","shell","stop"]
  
  
  
  [AndroidDriver] Cannot shut down Android driver; it has already shut     
  down
  
  [MJSONWP] Encountered internal error running command: Error: Error     
  executing adbExec. Original error: Command 
  '/Users/user1/Library/Android/sdk/platform-tools/adb -P 5037 -s 
  emulator-5554 shell stop' exited with code 
  1{"stdout":"","stderr":"stop: must be root\n","code":1}
      at ADB.execFunc$ (lib/tools/system-calls.js:189:13)
      at tryCatch 
  (/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modul
  es/babel-runtime/regenerator/runtime.js:67:40)
      at GeneratorFunctionPrototype.invoke [as _invoke]     (/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modul    es/babel-runtime/regenerator/runtime.js:315:22)
      at GeneratorFunctionPrototype.prototype.(anonymous function) [as 
  throw] 
  (/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modul    es/babel-runtime/regenerator/runtime.js:100:21)
      at GeneratorFunctionPrototype.invoke     
  (/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modul    es/babel-runtime/regenerator/runtime.js:136:37)
      at run     
  (/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modul    es/babel-runtime/node_modules/core-    
  js/library/modules/es6.promise.js:104:47)
      at     
  /Applications/Appium.app/Contents/Resources/node_modules/appium/node_module    s/babel-runtime/node_modules/core-    
  js/library/modules/es6.promise.js:115:28
      at flush 
  (/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modul    es/babel-runtime/node_modules/core-js/library/modules/$.microtask.js:19:5)
  at _combinedTickCallback (internal/process/next_tick.js:67:7)
  at process._tickCallback (internal/process/next_tick.js:98:9)
  </code></pre>
  
  <p>Below is my Appium logs
  what is it that I'm doing wrong here?</p>