nickirk/immo

Script doesn't work correctly

Closed this issue · 12 comments

Hi,

I tried to start your script as you provided but I get the following issue:

image

Do you know how to fix this issue?

Im using Python 2.7 on Debian

Regards,

hopppiii

Do you have a href.json or href_old.json file in your current directory? If yes, try to delete them and rerun the script. This could happen also when the internet is not working properly so no information is obtained from the website. Check if the href.json file is empty. I will probably push a fix to this this weekend. Thanks for reporting.

The href.jason file was empty. I delted it and rerunned the script but the href.jason file is still empty and I get them same error as before. I am using the script in a V. I guess that shouldn be a problem? I also checked that i have an internet connection. Thank you in advance for fixing!

Hi, I tested with python3 without modifying anything and the script works. Could you tell me what modifications you have made in the script?

Hi,

I guess it works now:

image

I forget to delete the # in front of my URL in the immo.spider.py ...

So when a new expose will appear it automatically write an email, correct? I also get a confirmation Mail from immoscout when the bot writes an email to the landlord, correct?

Do you know if it's possible to run the script on a raspberry pi 3 model b? Im asking because I think that the chromedriver just works on a 64 bit architecture. Does it?

regards,

hopppiii

Yes, that's how it works in principle if you have set up everything correctly according to the README .

I was able to set it up to work on my Raspberry pi, which is the same model as yours, so it is possible. You just need to install the correct version. Search on Google about how to install chromedriver on your model.

Hi,

I saw that the bot wrote an email to a landlord but I didnt received a confirmation mail. Do you know if immoscout blocks the bot? Is it possible to test the bot in this case?

If you have an account on immoscout with the same email address that you fill into the form as the username, then immoscout will send you an confirmation email. That's what happened to me. I don't know if you registered with the same email address or not.

If you saw the bot sent an email, then it means it is not blocked.

Hi,

I currently try to install the bot on my new Raspberry Pi. I just get the following issue with the chromedriver.

I receive the following message when the bot wants to write a new message:

Traceback (most recent call last): File "immo.py", line 58, in <module> submit.submit_app(new) File "/home/pi/immobot/submit.py", line 7, in submit_app driver=webdriver.Chrome('/usr/bin/chromedriver') File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/chrome/webdriver.py", line 81, in __init__ desired_capabilities=desired_capabilities) File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 157, in __init__ self.start_session(capabilities, browser_profile) File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 252, in start_session response = self.execute(Command.NEW_SESSION, parameters) File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/webdriver.py", line 321, in execute self.error_handler.check_response(response) File "/usr/local/lib/python2.7/dist-packages/selenium/webdriver/remote/errorhandler.py", line 242, in check_response raise exception_class(message, screen, stacktrace) selenium.common.exceptions.WebDriverException: Message: unknown error: Chrome failed to start: exited abnormally (unknown error: DevToolsActivePort file doesn't exist) (The process started from chrome location /usr/bin/chromium-browser is no longer running, so ChromeDriver is assuming that Chrome has crashed.) (Driver info: chromedriver=72.0.3626.121,platform=Linux 4.14.98-v7+ armv7l)

Can you please tell me which chromedriver do you use for your Pi and provide me the link or the command to install?

When I use "sudo apt-get install chromedriver" I get an message that there exist no installationcandidate for this package.

Thank you in advance!

Any hints :)?

I buyed the following model "Raspberry Pi 3 Modell B+" and tried several versions of chromium and read a lot of threads regarding installing chromium for pi. Do you use python 2.7 or 3.0? Which model do you use? In case you having the same model and os (noobs for pi) your way of installing chromium should work for me too, right?

I have the same model as yours. I remember I followed this link:
https://www.reddit.com/r/selenium/comments/7341wt/success_how_to_run_selenium_chrome_webdriver_on/
One thing I did not point out in README is that one might need to install selenium, too, if it is not preinstalled. See the link above.

Good luck and let me know if it works.