新手编码员再次在这里遇到另一个可能很简单的问题,我无法找到解决方案。
我在使用 InstaPy 时遇到错误,类似于每个人在此处发现的错误(https://github.com/timgrossmann/InstaPy/pull/6143),我正在尝试将 like_util.py 文件编辑为在此拉取请求中建议。但是我无法在我的 mac 中找到 like_util 文件。
当我打开 InstaPy 文件夹时,它有一些 .db 文件和一个 .xpi 文件。(见附件截图)我安装了 sqlitebrowser,但 like_util.py 文件不在 instapy.db 文件中。我不确定在哪里可以找到 InstaPy 的这些源文件。sqlite 浏览器的截图也附上了。
我意识到这是一个简单的问题,非常感谢任何帮助。
这是我要运行的代码:
#real bot
from time import sleep
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
from instapy import InstaPy
browser = webdriver.Firefox(executable_path = '/Applications/Python 3.9/geckodriver')
browser.quit()
sesh = InstaPy(username="dave", password="pass",geckodriver_path= r'/Applications/Python 3.9/geckodriver')
sesh.login()
sesh.like_by_tags(["ween","townie"])
browser.implicitly_wait(10)
sleep(5)
print('whoah there!!!')
sleep(1)
browser.quit()
以及尝试根据主题标签点赞帖子时的问题:
INFO [2021-10-07 19:40:42] [townierecords] Cannot detect post media type. Skip https://www.instagram.com/p/CUut0UWl-45/
INFO [2021-10-07 19:41:07] [townierecords] Cannot detect post media type. Skip https://www.instagram.com/p/CUusbU2Ik-a/
INFO [2021-10-07 19:41:33] [townierecords] Cannot detect post media type. Skip https://www.instagram.com/p/CUuo5VAF1ey/
INFO [2021-10-07 19:42:10] [townierecords] Cannot detect post media type. Skip https://www.instagram.com/p/CUvM12ppavg/
INFO [2021-10-07 19:42:10] [townierecords] Cannot detect post media type. Skip https://www.instagram.com/p/CUvM12ppavg/
INFO [2021-10-07 19:42:10] [townierecords] Cannot detect post media type. Skip https://www.instagram.com/p/CUvM12ppavg/
INFO [2021-10-07 19:42:10] [townierecords] Cannot detect post media type. Skip https://www.instagram.com/p/CUvM12ppavg/
INFO [2021-10-07 19:42:10] [townierecords] Cannot detect post media type. Skip https://www.instagram.com/p/CUvM12ppavg/
INFO [2021-10-07 19:42:35] [townierecords] Cannot detect post media type. Skip https://www.instagram.com/p/CUvGIXYJ4Dv/
INFO [2021-10-07 19:43:00] [townierecords] Cannot detect post media type. Skip https://www.instagram.com/p/CUvGAFCr9dx/
INFO [2021-10-07 19:43:25] [townierecords] Cannot detect post media type. Skip https://www.instagram.com/p/CUvFzJTpgHK/