Explore Courses Blog Tutorials Interview Questions
0 votes
in AWS by (19.1k points)

I've run into an interesting exception but I have no idea what caused it.

This is my exception: 

File "/Users/tai/Documents/workspace/testSelenium/testS/", line 86, in runFlashY

    openWebsites()    File "/Users/tai/Documents/workspace/testSelenium/testS/", line 50, in openWebsites

     newSwfFiles = Sniffer.openURL(line, []);

 File "/Users/tai/Documents/workspace/testSelenium/testS/", line 98, in openURL


 File "/Users/tai/Documents/workspace/testSelenium/testS/", line 211, in getAllFiles

outUrl= getredirectedUrl(b[place]);

  File "/Users/tai/Documents/workspace/testSelenium/testS/", line 249, in getredirectedUrl


 File "/Library/Python/2.7/site-packages/selenium/webdriver/remote/", line 178, in get

self.execute(Command.GET, {'url': url})

  File "/Library/Python/2.7/site-packages/selenium/webdriver/remote/", line 166, in execute


  File "/Library/Python/2.7/site-packages/selenium/webdriver/remote/", line 164, in check_response

    raise exception_class(message, screen, stacktrace)

selenium.common.exceptions.WebDriverException: Message: u'f.QueryInterface is not a function' ;       Stacktrace: 

    at FirefoxDriver.prototype.get (file:///var/folders/w5/w7rmb9zj7sz3wv8pq64c8h3h0000gn/T/tmpQcIHoK/extensions/[email protected]/components/driver_component.js:8768)

    at DelayedCommand.prototype.executeInternal_/h (file:///var/folders/w5/w7rmb9zj7sz3wv8pq64c8h3h0000gn/T/tmpQcIHoK/extensions/[email protected]/components/command_processor.js:10884)

    at DelayedCommand.prototype.executeInternal_ (file:///var/folders/w5/w7rmb9zj7sz3wv8pq64c8h3h0000gn/T/tmpQcIHoK/extensions/[email protected]/components/command_processor.js:10889)

    at DelayedCommand.prototype.execute/<    (file:///var/folders/w5/w7rmb9zj7sz3wv8pq64c8h3h0000gn/T/tmpQcIHoK/extensions/[email protected]/components/command_processor.js:10831) 

I googled this exception and only found a few websites that had anything related to this error, however, none of them had a solution that I understood. What is weird to me is that for the past 1 month I haven't run into this error and today when it has started occurring I wasn't working on this file.

The only modifications I have been making are in another file where I've been setting up a DynamoDb connection. I don't see how this could be related. In addition, I was working with the dynamodb connection file and there is no way that the code is related. The URL's I'm feeding in have not changed, none of the code in the files referenced in the error has been edited for days. I tried reverting to an earlier phase in my code but the error still appears sometimes.

I know that it's reading in urls from a text file and then opening them up with selenium webdriver. The only thing I can point to that I've changed is updating my computer with the latest Apple software update. Has anyone else had this experience? Before this began failing I updated my MacBook air to EFI firmware update version 2.8. 

I can't see a reason why editing another file would cause this error since the exception appears to be occurring in the web driver's .get function. 

I'm checking my sanity here, I can't find what could have triggered this. There is little to no documentation online on this error (exactly 5 google results as of posting). 

1 Answer

0 votes
by (44.4k points)

Parsing it wrong in the config can cause this:

selenium.common.exceptions.WebDriverException: Message: u'f.QueryInterface is not a function'

The URL should be without quotes, so in this just remove the quotes.

Your error here self.execute(Command.GET, {'url': url})

Related questions

Browse Categories