Comments (25)
Hello @sudha88
Protractor uses the developer tools to connect with chrome. When the devtools window is open protractor cannot issue commands.
If you want to use the developer tools you need to open a second tab pointing to the same URL as the first tab. Then open the devtools in the second tab.
from elementor.
Yes. I did that as you mentioned in your instructions but I was not able to see any locators. Can you think of any other reason?
Sent from my iPhone
On Mar 7, 2015, at 2:25 PM, Andres Dominguez [email protected] wrote:
Hello @sudha88
Protractor uses the developer tools to connect with chrome. When the devtools window is open protractor cannot issue commands.
If you want to use the developer tools you need to open a second tab pointing to the same URL as the first tab. Then open the devtools in the second tab.
—
Reply to this email directly or view it on GitHub.
from elementor.
Try to select a couple of nodes in the developer tools. The extension fires when you change the currently selected item. Do you see the log in the terminal moving?
Let me know if it works.
from elementor.
I have to board a plane. I will take a look at it tomorrow.
Can you tell me your node version?
from elementor.
node version v0.10.36
On Sat, Mar 7, 2015 at 3:13 PM, Andres Dominguez [email protected]
wrote:
I have to board a plane. I will take a look at it tomorrow.
Can you tell me your node version?
—
Reply to this email directly or view it on GitHub
#7 (comment)
.
Thanks,
Sudha
from elementor.
Hi Andres
I updated to protractor 1.8 and after that see some changes in protractor
logs in developer tools..I now see locators they are accompanied with
errors.Please see examples below.
- by.css('.action.clickable'): "There was a webdriver error: TypeError
Invalid locator" - by.css('div.action.clickable'): "There was a webdriver error:
TypeError Invalid locator" - by.css('div[ng-click="openGiftDialog()"]'): "There was a webdriver
error: TypeError Invalid locator" - by.css('div[ng-if="!giftSelected"]'): "There was a webdriver error:
TypeError Invalid locator"
On Sat, Mar 7, 2015 at 10:30 PM, Sudha Menon [email protected] wrote:
node version v0.10.36
On Sat, Mar 7, 2015 at 3:13 PM, Andres Dominguez <[email protected]
wrote:
I have to board a plane. I will take a look at it tomorrow.
Can you tell me your node version?
—
Reply to this email directly or view it on GitHub
#7 (comment)
.Thanks,
Sudha
Thanks,
Sudha
from elementor.
I am getting the exact same errors. Windows 7 32bit, Node v0.12.0,npm v2.51
Protractor v1.8.0 (installed globally only), Elementor v0.1.2
C:>elementor http://www.angularjs.org
Getting page at: http://www.angularjs.org
Listening on port 13000
Testing locators { byCss:
{ nodeName: 'div',
'app-run': 'hello.html',
class: 'well ng-scope' } }
Testing locator list [ { name: 'byCss',
locator: 'by.css('div[app-run="hello.html"]')',
countExpression: 'element.all(by.css('div[app-run="hello.html"]')).count()
' },
{ name: 'byCss',
locator: 'by.css('div.well')',
countExpression: 'element.all(by.css('div.well')).count()' },
{ name: 'byCss',
locator: 'by.css('.well')',
countExpression: 'element.all(by.css('.well')).count()' } ]
Sending locator results { 'by.css('div[app-run="hello.html"]')': 'There was a
webdriver error: TypeError Invalid locator',
'by.css('div.well')': 'There was a webdriver error: TypeError Invalid locato
r',
'by.css('.well')': 'There was a webdriver error: TypeError Invalid locator'
}
//========================================================
C:\Users\Mick>webdriver-manager start
seleniumProcess.pid: 3188
11:17:23.556 INFO - Launching a standalone server
Setting system property webdriver.chrome.driver to C:\Users\Mick\AppData\Roaming
\npm\node_modules\protractor\selenium\chromedriver.exe
11:17:23.796 INFO - Java: Oracle Corporation 25.20-b23
11:17:23.797 INFO - OS: Windows 7 6.1 x86
11:17:23.813 INFO - v2.45.0, with Core v2.45.0. Built from revision 5017cb8
11:17:24.009 INFO - RemoteWebDriver instances should connect to: http://127.0.0.1:4444/wd/hub
11:17:24.011 INFO - Version Jetty/5.1.x
11:17:24.013 INFO - Started HttpContext[/selenium-server,/selenium-server]
11:17:24.201 INFO - Started org.openqa.jetty.jetty.servlet.ServletHandler@c6a292
11:17:24.201 INFO - Started HttpContext[/wd,/wd]
11:17:24.201 INFO - Started HttpContext[/selenium-server/driver,/selenium-server
/driver]
11:17:24.202 INFO - Started HttpContext[/,/]
11:17:24.208 INFO - Started SocketListener on 0.0.0.0:4444
11:17:24.209 INFO - Started org.openqa.jetty.jetty.Server@11bc7ed
11:19:45.139 INFO - Executing: [new session: Capabilities [{browserName=chrome,
chromeOptions={args=[--load-extension=C:\Users\Mick\AppData\Roaming\npm\node_mod
ules\elementor\extension]}}]])
11:19:45.175 INFO - Creating a new session for Capabilities [{browserName=chrome
, chromeOptions={args=[--load-extension=C:\Users\Mick\AppData\Roaming\npm\node_m
odules\elementor\extension]}}]
Starting ChromeDriver 2.14.313457 (3d645c400edf2e2c500566c9aa096063e707c9cf) on
port 44940
Only local connections are allowed.
11:19:48.222 INFO - Done: [new session: Capabilities [{browserName=chrome, chrom
eOptions={args=[--load-extension=C:\Users\Mick\AppData\Roaming\npm\node_modules
elementor\extension]}}]]
11:19:48.426 INFO - Executing: [set script timeoutt: 11000])
11:19:48.597 INFO - Done: [set script timeoutt: 11000]
11:19:48.701 INFO - Executing: [get: http://www.angularjs.org])
11:19:57.441 INFO - Done: [get: http://www.angularjs.org]
11:20:36.950 INFO - Executing: [execute async script: try {
from elementor.
Hey,
just started using it.
great idea but I also get those:
'by.css('#searchInput')': 'There was a webdriver error: TypeError Invalid locator',
'by.css('input[autofocus=""]')': 'There was a webdriver error: TypeError Invalid locator',
'by.css('input.form-control')': 'There was a webdriver error: TypeError Invalid locator',
'by.css('.form-control')': 'There was a webdriver error: TypeError Invalid locator',
'by.css('input[type="search"]')': 'There was a webdriver error: TypeError Invalid locator',
'by.css('input[placeholder="Enter name"]')': 'There was a webdriver error: TypeError Invalid locator',
'by.css('input[ng-model="searchTerm"]')': 'There was a webdriver error: TypeError Invalid locator',
'by.id('searchInput')': 'There was a webdriver error: TypeError Invalid locator',
'by.model('searchTerm')': 1 }
from elementor.
I was finally able to reproduce the error. I haven't been able to find the cause, but I promise I will.
In the meantime, please use the github version:
$ git clone https://github.com/andresdominguez/elementor.git
$ ./elementor/bin/elementexplorer.js [url]
from elementor.
Hi,
I am still getting the error "There was a webdriver error: TypeError Invalid locator" even with the github version of elementor.
from elementor.
I also am seeing this issue on Mac - Node 0.10.32
Heres my console logs after trying to get element for both Elementor and webdriver manager.
Elementor Term:
Getting page at: https://angularjs.org
Listening on port 13000
Testing locators { byCss:
{ nodeName: 'a',
class: 'learn-link',
href: 'http://angular.codeschool.com' },
byLinkText: '\n \n Learn Angular in your browser for free!\n ' }
Testing locator list [ { name: 'byCss',
locator: 'by.css('a.learn-link')',
countExpression: 'element.all(by.css('a.learn-link')).count()' },
{ name: 'byCss',
locator: 'by.css('.learn-link')',
countExpression: 'element.all(by.css('.learn-link')).count()' },
{ name: 'byCss',
locator: 'by.css('a[href="http://angular.codeschool.com"]')',
countExpression: 'element.all(by.css('a[href="http://angular.codeschool.com"]')).count()' },
{ name: 'byLinkText',
locator: 'by.linkText('Learn Angular in your browser for free!')',
countExpression: 'element.all(by.linkText('Learn Angular in your browser for free!')).count()' } ]
Sending locator results { 'by.css('a.learn-link')': 'There was a webdriver error: TypeError Invalid locator',
'by.css('.learn-link')': 'There was a webdriver error: TypeError Invalid locator',
'by.css('a[href="http://angular.codeschool.com"]')': 'There was a webdriver error: TypeError Invalid locator',
'by.linkText('Learn Angular in your browser for free!')': 'There was a webdriver error: TypeError Invalid locator' }
WebDriver Term:
9:39:34.988 INFO - Done: [get: https://angularjs.org]
09:40:14.609 INFO - Executing: [execute async script: try { return (function (rootSelector, callback) {
var el = document.querySelector(rootSelector);
try {
if (!window.angular) {
throw new Error('angular could not be found on the window');
}
if (angular.getTestability) {
angular.getTestability(el).whenStable(callback);
} else {
if (!angular.element(el).injector()) {
throw new Error('root element (' + rootSelector + ') has no injector.' +
' this may mean it is not inside ng-app.');
}
angular.element(el).injector().get('$browser').
notifyWhenNoOutstandingRequests(callback);
}
} catch (err) {
callback(err.message);
}
}).apply(this, arguments); }
catch(e) { throw (e instanceof Error) ? e : new Error(e); }, [body]])
09:40:14.621 INFO - Done: [execute async script: try { return (function (rootSelector, callback) {
var el = document.querySelector(rootSelector);
try {
if (!window.angular) {
throw new Error('angular could not be found on the window');
}
if (angular.getTestability) {
angular.getTestability(el).whenStable(callback);
} else {
if (!angular.element(el).injector()) {
throw new Error('root element (' + rootSelector + ') has no injector.' +
' this may mean it is not inside ng-app.');
}
angular.element(el).injector().get('$browser').
notifyWhenNoOutstandingRequests(callback);
}
} catch (err) {
callback(err.message);
}
}).apply(this, arguments); }
catch(e) { throw (e instanceof Error) ? e : new Error(e); }, [body]]
09:40:14.631 INFO - Executing: [execute async script: try { return (function (rootSelector, callback) {
var el = document.querySelector(rootSelector);
try {
if (!window.angular) {
throw new Error('angular could not be found on the window');
}
if (angular.getTestability) {
angular.getTestability(el).whenStable(callback);
} else {
if (!angular.element(el).injector()) {
throw new Error('root element (' + rootSelector + ') has no injector.' +
' this may mean it is not inside ng-app.');
}
angular.element(el).injector().get('$browser').
notifyWhenNoOutstandingRequests(callback);
}
} catch (err) {
callback(err.message);
}
}).apply(this, arguments); }
catch(e) { throw (e instanceof Error) ? e : new Error(e); }, [body]])
09:40:14.639 INFO - Done: [execute async script: try { return (function (rootSelector, callback) {
var el = document.querySelector(rootSelector);
try {
if (!window.angular) {
throw new Error('angular could not be found on the window');
}
if (angular.getTestability) {
angular.getTestability(el).whenStable(callback);
} else {
if (!angular.element(el).injector()) {
throw new Error('root element (' + rootSelector + ') has no injector.' +
' this may mean it is not inside ng-app.');
}
angular.element(el).injector().get('$browser').
notifyWhenNoOutstandingRequests(callback);
}
} catch (err) {
callback(err.message);
}
}).apply(this, arguments); }
catch(e) { throw (e instanceof Error) ? e : new Error(e); }, [body]]
09:40:14.649 INFO - Executing: [execute async script: try { return (function (rootSelector, callback) {
var el = document.querySelector(rootSelector);
try {
if (!window.angular) {
throw new Error('angular could not be found on the window');
}
if (angular.getTestability) {
angular.getTestability(el).whenStable(callback);
} else {
if (!angular.element(el).injector()) {
throw new Error('root element (' + rootSelector + ') has no injector.' +
' this may mean it is not inside ng-app.');
}
angular.element(el).injector().get('$browser').
notifyWhenNoOutstandingRequests(callback);
}
} catch (err) {
callback(err.message);
}
}).apply(this, arguments); }
catch(e) { throw (e instanceof Error) ? e : new Error(e); }, [body]])
09:40:14.656 INFO - Done: [execute async script: try { return (function (rootSelector, callback) {
var el = document.querySelector(rootSelector);
try {
if (!window.angular) {
throw new Error('angular could not be found on the window');
}
if (angular.getTestability) {
angular.getTestability(el).whenStable(callback);
} else {
if (!angular.element(el).injector()) {
throw new Error('root element (' + rootSelector + ') has no injector.' +
' this may mean it is not inside ng-app.');
}
angular.element(el).injector().get('$browser').
notifyWhenNoOutstandingRequests(callback);
}
} catch (err) {
callback(err.message);
}
}).apply(this, arguments); }
catch(e) { throw (e instanceof Error) ? e : new Error(e); }, [body]]
09:40:14.667 INFO - Executing: [execute async script: try { return (function (rootSelector, callback) {
var el = document.querySelector(rootSelector);
try {
if (!window.angular) {
throw new Error('angular could not be found on the window');
}
if (angular.getTestability) {
angular.getTestability(el).whenStable(callback);
} else {
if (!angular.element(el).injector()) {
throw new Error('root element (' + rootSelector + ') has no injector.' +
' this may mean it is not inside ng-app.');
}
angular.element(el).injector().get('$browser').
notifyWhenNoOutstandingRequests(callback);
}
} catch (err) {
callback(err.message);
}
}).apply(this, arguments); }
catch(e) { throw (e instanceof Error) ? e : new Error(e); }, [body]])
09:40:14.675 INFO - Done: [execute async script: try { return (function (rootSelector, callback) {
var el = document.querySelector(rootSelector);
try {
if (!window.angular) {
from elementor.
Me too getting the same error.
from elementor.
On another note, this occurs also within the Webstorm Plugin. Users are not able to test directly inside webstorm
from elementor.
Same here, no matter what I try, I get the same result :
{ 'element.all(by.css('div')).count()': 'There was a webdriver error: TypeError Invalid locator' }
Mac - Node 0.10.31 - Protractor 1.6.1 - npm 1.4.23 - Elementor 0.1.8
from elementor.
Quick update:
I am working with the protractor team to fix this bug for good. The element explorer implementation changed after protractor 1.6.
Wait a few more days and I promise it will get fixed. I haven't forgotten.
Andres
from elementor.
Great !
from elementor.
Thanks! Looking forward to the update:)
Edit:
Any updates on this update??
from elementor.
+1
from elementor.
Any updates on this fix?
from elementor.
The protractor team already made the change I requested. I have it running on my machine.
I already migrated to the head version of protractor. The change didn't make it to protractor 2.0.0.
I have to figure out a way to ship a local protractor version with elementor until they release the next protractor version. It should be done this week.
from elementor.
I just pushed a new version to npm (1.0.4). It seems to be working. I will try to stress test it today to find bugs. The implementation is very different from the previous version, it may contain some bugs.
from elementor.
Thank you Andres .I will help test too.
On Tue, Mar 31, 2015 at 9:01 AM, Andres Dominguez [email protected]
wrote:
I just pushed a new version to npm (1.0.4). It seems to be working. I will
try to stress test it today to find bugs. The implementation is very
different from the previous version, it may contain some bugs.—
Reply to this email directly or view it on GitHub
#7 (comment)
.
Thanks,
Sudha
from elementor.
Logging another issue that I'm seeing. Do we need to do anything besides update elementor (through npm) to get this to work?
from elementor.
I"m still on protractor 1.8 but I'm assuming since (1.0.4) you packaged it with it's own version of protractor that doesn't matter? I still get 'There was a webdriver error: TypeError Invalid locator' }
also I'm using the --nonAngular flag
from elementor.
This issue was fixed on version 1.0.7. Let me know if the problem persists.
from elementor.
Related Issues (20)
- finding suggestions always HOT 2
- Allow user choose section ID
- How to select an element inside an iframe ? Is there a way to switch inside an iframe and select an element from there ?
- Fatal error on install plugin
- Elementor text input looks broken and can't be used HOT 1
- Using elementor with responsive design?
- Elementor is not running as root HOT 1
- Elementor W3 validator issue
- chormedriver_2.30.exe is opening in background but unable to launch the chrome browser with elementor HOT 2
- Does not work with latest version of Chrome HOT 4
- Accordion and Toggle not working with Elementor PRO?
- Protractor , Elementor unable to launch url from windows 10 HOT 4
- Elementor not able to launch URL in chrome HOT 1
- How to create a portfolio with elementor pro, with categories, filters, but with title under image?
- Getting Error Launching Elementor HOT 2
- Is the Elementor project alive?
- Is Elementor alive?
- Elementor extension is not working on latest chrome Version 69.0.3497.100 HOT 1
- Elementor is always finding suggestions HOT 2
- Elementor extension not working with latest node version v11.13.0 HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from elementor.