Instapy: InstaPy for Dummies :(

Created on 8 May 2017  路  28Comments  路  Source: timgrossmann/InstaPy

Despite many attempts I am not able to apply the procedure. A charitable soul to explain to a perfect beginner, how to succeed the whole process in order to understand and test InstaPy?
Thanks in advance to the community and Tim bravo for the work

help wanted

Most helpful comment

i got stuck at installing pyvirtualdriver :/
wasn't able to install Xvfb, Xephyr nor Xvnc... can anybody help please?

EDIT1:
I've installed homebrew and tried this:
brew install xserver-xephyr
but I'm only getting:
Error: No available formula with the name "xserver-xephyr"
==> Searching for a previously deleted formula...
Error: No previously deleted formula found.
==> Searching for similarly named formulae...
Error: No similarly named formulae found.
==> Searching taps...
Error: No formulae found in taps.

EDIT2:
found a solution:
I Installed Docker instead of Xvfb, Xephyr or Xvnc
then in the terminal:
sudo su
then
pip install pyvirtualdisplay

All 28 comments

Can you tell us more about your setup?
What have you tried so far?

Alos let us know your platform(windows or mac) and what all did you install already?

My platform is mac, I installed Python 3.6.1, and I admit that after has a great moment of solitude, I can not install selenium nor pyvirtualdriver. I think I have "assured" on chromedriver and nothing more :(
Thank you for taking time to help me sincerely
Pat

Okay.
Can you follow the steps here to get pip installed? - just fire the commands as written.

Once done, follow the steps in the README.

cd InstaPy
python setup.py install

After that open the quickstart.py and put in your username password and save and close.
And then run the quickstart by:
python quickstart.py
Lets see what happens.

I've been trying to install InstaPy on MacOS too. I ended up installing Ubuntu Server 14.04 on my Mac via VirtualBox. Now everything works like a charm.

@cazaa What went wrong when you were setting it up on Mac?

@littleswany When I run py quickstart.py I get the following error:

Traceback (most recent call last):
File "quickstart.py", line 14, in <module>
InstaPy(nogui=True)\
File "/Users/cazaa/InstaPy/instapy/instapy.py", line 29, in __init__
self.display = Display(visible=0, size=(800, 600))
File "build/bdist.macosx-10.12-intel/egg/pyvirtualdisplay/display.py", line 34, in __init__
File "build/bdist.macosx-10.12-intel/egg/pyvirtualdisplay/display.py", line 52, in display_class
File "build/bdist.macosx-10.12-intel/egg/pyvirtualdisplay/xvfb.py", line 38, in check_installed
File "build/bdist.macosx-10.12-intel/egg/easyprocess/__init__.py", line 180, in check_installed
easyprocess.EasyProcessCheckInstalledError: cmd=['Xvfb', '-help']
OSError=[Errno 2] No such file or directory
Program install error!

I learned from searching for _xvfb for mac_ that _xvfb_ apparently does not exist for MacOS. I might be wrong though. Installing VirtualBox and Ubuntu seemed like a much easier solution at that point :)

@cazaa Try changing nogui=True to nogui=False in your quickstart.py

@littleswany Thank you so much! Now it works! 馃懐

Thanks @sunnypatel165.
I tried to follow the instructions for the PIP but how to know if everything went well?
I typed the instructions into the terminal

But i still do not understand how to install selenium :(
I'm really bad :( :(

When I Type the Command Line
pip install selenium
I get this answer
-bash: pip: command not found

@tricepad Did you follow the steps as is? Can you attach a screenshot of step 5 and what you got as the output?
Also, can you quickly run the following commands and tell what the output is?

which python
which pip
python --version
pip --version

hy !

Python 2.7.10
pip 9.0.1 from /Library/Python/2.7/site-packages/pip-9.0.1-py2.7.egg (python 2.7)

capture d ecran 2017-05-10 a 20 23 55

Person to help me?
Please :(

@tricepad Install Python3 first...

Thank you tim, I installed Python 3, I thought but in the terminal it is always the 2.7.10 that emerges 馃檲馃檲

@tricepad when you run any python command that is something like python dothis.py, you can force python3 by using python3 dothis.py instead. Similarly for pip and pip3. Try following the steps again with Python3.

ok

capture d ecran 2017-05-20 a 13 50 31

error message :(

capture d ecran 2017-05-20 a 13 54 29

Should I restart my mac when the python installation was done?

@tricepad the dothis.py was just an example...

Do this with the quickstart.py in the actual folder

@tricepad
try sudo pip3 install selenium

i got stuck at installing pyvirtualdriver :/
wasn't able to install Xvfb, Xephyr nor Xvnc... can anybody help please?

EDIT1:
I've installed homebrew and tried this:
brew install xserver-xephyr
but I'm only getting:
Error: No available formula with the name "xserver-xephyr"
==> Searching for a previously deleted formula...
Error: No previously deleted formula found.
==> Searching for similarly named formulae...
Error: No similarly named formulae found.
==> Searching taps...
Error: No formulae found in taps.

EDIT2:
found a solution:
I Installed Docker instead of Xvfb, Xephyr or Xvnc
then in the terminal:
sudo su
then
pip install pyvirtualdisplay

Ok, so I finally got everything installed and executed the quickstart script as it is, simply with my login credentials as a test.
Chrome opens, login is executed, the first hashtag is being searched (dog)...
and then all what happens is scrolling down, wait until new content is loaded, scroll up and then scrolling down, wait until new content is loaded, and so on. It's stuck in loop and nothing else happens.

I'm working on a mac with python 3.6

Would be very thankful if somebody could help! Thanks.

@mrandidemartini That shouldn't happen.
Can you share your quickstart? Maybe you have specified a very high value for count, try with a smaller number to test!

thanks @sunnypatel165 , this resolved the problem!

tried installing on os x 10.9.5, Python 2.7 - can't get past pip install pyvirtualdriver. I get "No matching distribution found for pyvirtualdriver". This might be due to lack of three back-ends mentioned (Xvfb, Xephyr, Xvnc) - I have no clue about installing any of these for mac. Can anyone help? My mac is too old for the Docker-installation from @mrandidemartini...

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ediooo picture ediooo  路  3Comments

drcyber975 picture drcyber975  路  3Comments

CharlesCCC picture CharlesCCC  路  3Comments

ingorichter picture ingorichter  路  3Comments

harrypython picture harrypython  路  3Comments