Update screenshot_downloader.py

pull/2081/head
Nathaniel Phillips 1 year ago committed by GitHub
parent 4d1cf64805
commit 68592c9768
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -181,6 +181,7 @@ def get_screenshots_of_reddit_posts(reddit_object: dict, screenshot_num: int):
location[i] = float("{:.2f}".format(location[i] * zoom)) location[i] = float("{:.2f}".format(location[i] * zoom))
page.screenshot(clip=location, path=postcontentpath) page.screenshot(clip=location, path=postcontentpath)
else: else:
page.wait_for_load_state('load')
page.locator('[data-test-id="post-content"]').screenshot(path=postcontentpath) page.locator('[data-test-id="post-content"]').screenshot(path=postcontentpath)
except Exception as e: except Exception as e:
print_substep("Something went wrong!", style="red") print_substep("Something went wrong!", style="red")

Loading…
Cancel
Save