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

Already on GitHub? Sign in to your account

error when trying to get an element within frame #191

Open
patrycja opened this Issue Mar 7, 2013 · 5 comments

Comments

Projects
None yet
4 participants

patrycja commented Mar 7, 2013

I've got an issue with iframes. I'm trying to get an element with the following code:

browser.frame(:index => 0).div(:id, "wrapper").exists?

and when I'm using phantomjs (1.8.1), it raise an error:

NameError: uninitialized constant Watir::FramedDriver::UnknownFrameException

Any ideas how can I get this element without getting an error?

Thanks,
Patrycja

Owner

detro commented Mar 10, 2013

It's practically impossible for me to debug this without seeing the HTML of the page you are testing.

If you can provide that I'd be happy to help.

Hi, thanks for looking at this issue.
The HTML code is here:
https://gist.github.com/patrycja/d774acb7d6e966d2bc18#file-gistfile1-txt-L564

hashwin commented Mar 17, 2013

+1 on this issue. Watir works fine with other drivers, but the iframe completely blows up when running with ghostdriver.

Owner

detro commented Jul 15, 2013

Unfortunately this is an issue with PhantomJS itself: QtWebKit doesn't list iframes within the list of frames when accessing via integer value (i.e. the n-th frame - in your case, you are trying to grab the first one).

There is nothing I can do for this.
I'll leave it here, and tag it as an issue related to PhantomJS.

@detro detro closed this Jul 15, 2013

@detro detro reopened this Jul 15, 2013

Contributor

loduis commented Aug 17, 2013

this problem is fixed in phantomjs 1.9.1
but if the next code html is real, this not work in any browser

<iframe style="visibility: visible;">
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment