Skip to content
New issue

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

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FP-Block-xpi here is different from the one uploaded at the official project website #1

Open
lkloh opened this issue Aug 4, 2016 · 0 comments

Comments

@lkloh
Copy link

lkloh commented Aug 4, 2016

When I install FP-Block in selenium using the plugin posted at the official project website, everything seems to work perfectly.

This is the source code I ran on a mac:

import time, sys                                                        # some prints                    # to press keys on a webpage
import shutil, errno
import os, platform                         # for running  os, platform specific function calls
from selenium import webdriver              # for running the driver on websites
from datetime import datetime               # for tagging log with datetime             
from selenium.webdriver.common.proxy import *       # for proxy settings
from selenium.webdriver.chrome.options import Options
from selenium.common.exceptions import NoSuchElementException


fp = webdriver.FirefoxProfile()

fp.set_preference("signatures.required", False)
fp.set_preference('browser.helperApps.neverAsk.accept', True)

"""disable cookies"""
fp.set_preference("network.cookie.cookieBehavior", 2)
fp.update_preferences()

"""add fpblock extension"""
fpblock_plugin = '../FP-Block.xpi'
fp.add_extension(fpblock_plugin)



driver = webdriver.Firefox(firefox_profile=fp)
print 'driver started'

driver.get('https://www.google.com/')
time.sleep(5)

I am interested in modifying the source code of FPblock to do something. Thus I tried installing FP-Block in selenium via the plugin produced by compiling the source code posted here. I got this error:

Traceback (most recent call last):
  File "test_script.py", line 50, in <module>
    driver.get('https://www.google.com/')
  File "/Library/Python/2.7/site-packages/selenium/webdriver/remote/webdriver.py", line 248, in get
    self.execute(Command.GET, {'url': url})
  File "/Library/Python/2.7/site-packages/selenium/webdriver/remote/webdriver.py", line 236, in execute
    self.error_handler.check_response(response)
  File "/Library/Python/2.7/site-packages/selenium/webdriver/remote/errorhandler.py", line 192, in check_response
    raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.WebDriverException: Message: Ci is undefined
Stacktrace:
    at _loadURIWithFlags (chrome://browser/content/browser.js:825)
    at loadURIWithFlags (chrome://browser/content/tabbrowser.xml:6697)
    at loadURI (chrome://global/content/bindings/browser.xml:114)
    at loadURI (chrome://browser/content/tabbrowser.xml:3836)
    at FirefoxDriver.prototype.get (file:///var/folders/gw/tncmz04d3h936y9jv_snsf740000gn/T/tmpxj_0bk/extensions/[email protected]/components/driver-component.js:10641)
    at DelayedCommand.prototype.executeInternal_/h (file:///var/folders/gw/tncmz04d3h936y9jv_snsf740000gn/T/tmpxj_0bk/extensions/[email protected]/components/command-processor.js:12661)
    at DelayedCommand.prototype.executeInternal_ (file:///var/folders/gw/tncmz04d3h936y9jv_snsf740000gn/T/tmpxj_0bk/extensions/[email protected]/components/command-processor.js:12666)
    at DelayedCommand.prototype.execute/< (file:///var/folders/gw/tncmz04d3h936y9jv_snsf740000gn/T/tmpxj_0bk/extensions/[email protected]/components/command-processor.js:12608)

Could you update the repository so that the code reflects the plugin posted on your official project website? Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant