{"action":"opened","issue":{"url":"https://api.github.com/repos/SeleniumHQ/selenium/issues/2116","repository_url":"https://api.github.com/repos/SeleniumHQ/selenium","labels_url":"https://api.github.com/repos/SeleniumHQ/selenium/issues/2116/labels{/name}","comments_url":"https://api.github.com/repos/SeleniumHQ/selenium/issues/2116/comments","events_url":"https://api.github.com/repos/SeleniumHQ/selenium/issues/2116/events","html_url":"https://github.com/SeleniumHQ/selenium/issues/2116","id":155381818,"number":2116,"title":"Promises in command paramaters cause Executor.execute() to fail","user":{"login":"johnjbarton","id":205570,"avatar_url":"https://avatars.githubusercontent.com/u/205570?v=3","gravatar_id":"","url":"https://api.github.com/users/johnjbarton","html_url":"https://github.com/johnjbarton","followers_url":"https://api.github.com/users/johnjbarton/followers","following_url":"https://api.github.com/users/johnjbarton/following{/other_user}","gists_url":"https://api.github.com/users/johnjbarton/gists{/gist_id}","starred_url":"https://api.github.com/users/johnjbarton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/johnjbarton/subscriptions","organizations_url":"https://api.github.com/users/johnjbarton/orgs","repos_url":"https://api.github.com/users/johnjbarton/repos","events_url":"https://api.github.com/users/johnjbarton/events{/privacy}","received_events_url":"https://api.github.com/users/johnjbarton/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-05-17T22:59:42Z","updated_at":"2016-05-17T22:59:42Z","closed_at":null,"body":"## Meta -\r\nOS:  All\r\n<!-- Windows 10? OSX? -->\r\nSelenium Version:  2.53\r\n<!-- 2.52.0, IDE, etc -->\r\nBrowser:  All\r\n<!-- Google Chrome?  Firefox? -->\r\nBrowser Version:  All\r\n<!-- e.g.: 49.0.2623.87 (64-bit) -->\r\n\r\n## Expected Behavior -\r\nexecute resolves parameters\r\n## Actual Behavior -\r\nfail in http POST because of a bad URL path:\r\n/session/[object Object]/window/current/maximize\r\n## Steps to reproduce -\r\n<!-- Please be sure to include an SSCCE (Short, Self Contained, Correct [compilable] example) http://sscce.org/ -->\r\n\r\n```js\r\n  var executor = Executors.createExecutor(selServer);\r\n  var browser = webdriver.WebDriver.attachToSession(executor, selId);\r\n  browser.manage().window().maximize().then(function() { ... never gets here\r\n```\r\nWhen we get to \r\n\r\nhttps://github.com/SeleniumHQ/selenium/blob/master/javascript/node/selenium-webdriver/http/index.js#L462\r\n\r\nThe command for window().maximize() still contains a promise for a sessionId. That is a result of setting the sessionId in \r\nhttps://github.com/SeleniumHQ/selenium/blob/a368fca55fe5e8d202face6cd0f505bffc38d319/javascript/node/selenium-webdriver/lib/webdriver.js#L357\r\nto `this.sessionId_` which is a promise:\r\nhttps://github.com/SeleniumHQ/selenium/blob/a368fca55fe5e8d202face6cd0f505bffc38d319/javascript/node/selenium-webdriver/lib/webdriver.js#L270\r\n\r\n"}}