InstaPy / InstaPy/instapy-quickstart
KeyError: "graphq1"
- Lingua principale
- Python
- Stelle
- 777
- Fork
- 763
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
Hello everyone,
I am a beginner in Instapy.
Foremost, I have change in file : like_until.py line 619 cause of a ["inappropriate, user_name, is_video, reason, scope = check_link()..."](https://stackoverflow.com/questions/71166123/instapy-issue-inappropriate-user-name-is-video-reason-scope-check-link) because my bot cannot like picture:
media = post_page['items'][0]
is_video = media["is_unified_video"]
user_name = media["user"]["username"]
image_text = media["caption"]["text"]
owner_comments = ""
Instead of :
media = post_page[0]["shortcode_media"]
is_video = media["is_video"]
user_name = media["owner"]["username"]
image_text = media["caption"]
owner_comments = browser.execute_script(
"""
latest_comments = window._sharedData.entry_data.PostPage[
0].media.comments.nodes;
if (latest_comments === undefined) {
latest_comments = Array();
owner_comments = latest_comments
.filter(item => item.user.username == arguments[0])
.map(item => item.text)
.reduce((item, total) => item + '\\n' + total, '');
return owner_comments;}
else {
return null;}
""",
user_name,
)
Now the bot can like one picture and then appear in line 523 :
Traceback (most recent call last):
File "/Users/Desktop/instapy-quickstart-master/run/../quickstart.py", line 39, in
session.like_by_tags(TAGS_A_SUIVRE, amount=10)
File "/Users/miniforge3/lib/python3.9/site-packages/instapy/instapy.py", line 2059, in like_by_tags
success = process_comments(
File "/Users/miniforge3/lib/python3.9/site-packages/instapy/comment_util.py", line 445, in process_comments
commented_image, message = verify_commented_image(browser, link, owner, logger)
File "/Users/miniforge3/lib/python3.9/site-packages/instapy/comment_util.py", line 366, in verify_commented_image
data = getMediaData("edge_media_to_parent_comment", browser)
File "/Users/miniforge3/lib/python3.9/site-packages/instapy/util.py", line 523, in getMediaData
data = additional_data["graphql"]["shortcode_media"]
KeyError: 'graphql'
What should I do ?
The script is attached.

Thanks for your response
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Valutazione
Questa issue non è ancora stata valutata.