Instaloader: No Attribute 'Instaloader'

Created on 9 Oct 2018  路  3Comments  路  Source: instaloader/instaloader

Pretty straight forward...trying to start instaloader. I have successfully downloaded using pip.

import instaloader

# Get instance
L = instaloader.Instaloader()

I continue to get the following error below. Can someone please help?

Traceback (most recent call last):
  File "il.py", line 1, in <module>
    import instaloader
  File "C:\Users\XXX\Desktop\instagram\instaloader.py", line 4, in <module>
    L = instaloader.Instaloader()
AttributeError: module 'instaloader' has no attribute 'Instaloader'
question

Most helpful comment

Python code last version

import instaloader
L = instaloader.Instaloader()

CMD windows:

C:\Users\XXX>python -c "import instaloader; print(instaloader)"
<module 'instaloader' from 'C:\\Python37\\lib\\site-packages\\instaloader\\__init__.py'>

but i see error

Traceback (most recent call last):
  File "C:/Python37/Laba/instaloader.py", line 1, in <module>
    import instaloader
  File "C:/Python37/Laba\instaloader.py", line 2, in <module>
    L = instaloader.Instaloader()
AttributeError: module 'instaloader' has no attribute 'Instaloader'

Hi! I'm dumb as you :) searching the solution second day. Rename your project name instaloader.py to another, different from name of lib instaloader.

All 3 comments

I suspect your Python installation may search in a wrong directory, and instead of the pip installation of Instaloader, it finds a some kind of broken installation.

What is the output of python3 -c "import sys; print(sys.path)"? It should print a list of directories where Python searches for modules sorted by their priority. Usually, one of the first is a directory named site-packages where pip installs Instaloader to. In that directory should be a subdirectory named 矛nstaloader with the same files that are in the instaloader/ directory in our Github repository.

Python code last version

import instaloader
L = instaloader.Instaloader()

CMD windows:

C:\Users\XXX>python -c "import instaloader; print(instaloader)"
<module 'instaloader' from 'C:\\Python37\\lib\\site-packages\\instaloader\\__init__.py'>

but i see error

Traceback (most recent call last):
  File "C:/Python37/Laba/instaloader.py", line 1, in <module>
    import instaloader
  File "C:/Python37/Laba\instaloader.py", line 2, in <module>
    L = instaloader.Instaloader()
AttributeError: module 'instaloader' has no attribute 'Instaloader'

Python code last version

import instaloader
L = instaloader.Instaloader()

CMD windows:

C:\Users\XXX>python -c "import instaloader; print(instaloader)"
<module 'instaloader' from 'C:\\Python37\\lib\\site-packages\\instaloader\\__init__.py'>

but i see error

Traceback (most recent call last):
  File "C:/Python37/Laba/instaloader.py", line 1, in <module>
    import instaloader
  File "C:/Python37/Laba\instaloader.py", line 2, in <module>
    L = instaloader.Instaloader()
AttributeError: module 'instaloader' has no attribute 'Instaloader'

Hi! I'm dumb as you :) searching the solution second day. Rename your project name instaloader.py to another, different from name of lib instaloader.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

psonnosp picture psonnosp  路  3Comments

milankhatir picture milankhatir  路  3Comments

kurttian picture kurttian  路  3Comments

annanny picture annanny  路  3Comments

Fickbert picture Fickbert  路  4Comments