I don't know why I get that error. Any idea on how to fix it ?
C:\Users\Administrator\Desktop\InstaPy-master\examples>python example1.py
[0521/063714.803:ERROR:gpu_process_transport_factory.cc(1007)] Lost UI shared context.
DevTools listening on ws://127.0.0.1:12863/devtools/browser/5136c527-78cd-4493-984d-7943cce2d319
INFO [2018-05-21 06:37:16] [X] Session started - 2018-05-21 06:37:16
WARNING [2018-05-21 06:37:16] [X] Sorry, Record Activity is not working on Windows. We're working to fix this soon!
Traceback (most recent call last):
File "example1.py", line 9, in <module>
session.login()
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python36-32\lib\site-packages\instagram_py-0.0.1-py3.6.egg\instapy\instapy.py", line 320, in login
self.bypass_suspicious_attempt):
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python36-32\lib\site-packages\instagram_py-0.0.1-py3.6.egg\instapy\login_util.py", line 100, in login_user
update_activity()
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python36-32\lib\site-packages\instagram_py-0.0.1-py3.6.egg\instapy\util.py", line 132, in update_activity
conn = sqlite3.connect(Settings.database_location)
sqlite3.OperationalError: unable to open database file
Hi @Raziel15
1. Is your database file (instapy.db) in db folder?
2. Do you use a custom database location by instantiating Settings class?
Settings.database_location = '/path/to/instapy.db'
_if yes, make sure locations are correct_
3. Do you have write access to the database file (instapy.db) and the directory containing it?
4. If there is no problem with the above steps, then re-download a fresh new instapy.db file from main repo and put it in db folder.
Cheers!
@jseps
Did you manage to solve your problem?
If not, I don't see the answers to my question in above comment.
Also, how did you install Instapy? (_e.g. from git or cloned to GitHub Desktop or installed from pip or downloaded ZIP_)
_By chance, if you have installed from pip, give a try to the fresh-new fix at #2080 by
@jaybocc2_
Cheers xD
@uluQulu
I did -- long story, but I somehow had 3 settings.py files relating to Instapy, and was editing the wrong ones. I cloned Instapy. Thank you!
Gald that it works @jseps
It's epic :D
BTW cloning to GitHub Desktop and using its amazing user interface is the best choice to having a clean folder structure and ease the process of getting new updates from repo.
I also use it most of time and only sometimes need git.
I was having the same problem when I installed with pip in virtualenv. Step 1. solved my problem. I had to add a db directory to /venv/lib/python3.6/site-packages/ then I downloaded instapy.db from the repo and added it to the db directory. Thanks for the answer @uluQulu!
@vastopa see https://github.com/timgrossmann/InstaPy/pull/2080#issuecomment-392996932
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. > If this problem still occurs, please open a new issue
Most helpful comment
I was having the same problem when I installed with pip in virtualenv. Step 1. solved my problem. I had to add a
dbdirectory to/venv/lib/python3.6/site-packages/then I downloadedinstapy.dbfrom the repo and added it to thedbdirectory. Thanks for the answer @uluQulu!