Code Monkey home page Code Monkey logo

Comments (3)

shaikhsajid1111 avatar shaikhsajid1111 commented on September 1, 2024

What browser it was? Google Chrome Or Mozilla Firefox? Can you please share more details?

from twitter-scraper-selenium.

Andreito95 avatar Andreito95 commented on September 1, 2024

it's the same, proxy (with authentication user/pass) doesn't work with both Chrome or Mozilla.
I have 10000 rows of python code with implemented Selenium browser, the only way to user proxy with authentication is Chrome and use an extension with a json file like this (you can find code around the web):

pluginfile = 'proxy_auth_plugin.zip'
with zipfile.ZipFile(pluginfile, 'w') as zp:
zp.writestr("manifest.json", manifest_json)
zp.writestr("background.js", background_js)
chrome_options.add_extension(pluginfile)

I am trying to find a better way (with both chrome or mozilla, i don't care) that works without exstentions (i would like to disable extensions but i can't because of this one for proxy on chrome).
Another thing i can tell you is that it's not possible to save cookies with Chrome with this extension, because it will give problems with proxy authentication, so i am actually using Chrome without cookies and with this extension to use it with proxy with user/pass auth.

I tried your code and i found lot of good and perfect funcitons, but if you can find a solution for the proxy with authentication it will be really helpful to me.
Tried both mozilla and chrome with your code and put right string "user:pass@ip:port", browser opens correctly but if you open "whatismyipaddress.com" it will show you the real IP (and not the proxy one), so it doesn't work.

from twitter-scraper-selenium.

shaikhsajid1111 avatar shaikhsajid1111 commented on September 1, 2024

I think you're right about this. Selenium doesn't have proper functionality when it comes to using an authenticated proxy. Even I encountered the same problem when I once used an authenticated proxy, yeah that problem is available to use some chrome extensions. I think it is the only option even I see is working. If I find some better solution somewhere I would love to implement it here but currently, I don't have one.

I think if your proxy provider provides whitelisting feature then you should consider using it, just whitelist the server although it doesn't really focus on the problem it does gives you an alternative way.

from twitter-scraper-selenium.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.