InstaPy / InstaPy/InstaPy

Exit Problem !

Open
#6,066 1 comment 0 reactions 0 assignees View on GitHub
wontfix
Dominant language
Python
Stars
18.2k
Forks
3.9k
PR merge metrics
No merged PRs in 30d

Description

## Expected Behavior
Closing Skript, Write Data, exit

## Current Behavior
"AttributeError: __enter__" at the End.

`INFO [2021-02-05 11:18:42] [hs.bau] --> Invalid Like Element!
Traceback (most recent call last):
File "/usr/local/lib/python3.8/dist-packages/instapy/util.py", line 1953, in smart_run
yield
File "firsttry.py", line 77, in
session.like_by_tags(hashtags, amount=10, use_random_tags=True)
File "/usr/local/lib/python3.8/dist-packages/instapy/instapy.py", line 2036, in like_by_tags
success = process_comments(
File "/usr/local/lib/python3.8/dist-packages/instapy/comment_util.py", line 475, in process_comments
commented_image, message = verify_commented_image(browser, link, owner, logger)
File "/usr/local/lib/python3.8/dist-packages/instapy/comment_util.py", line 393, in verify_commented_image
data = browser.execute_script(
File "/usr/local/lib/python3.8/dist-packages/selenium/webdriver/remote/webdriver.py", line 634, in execute_script
return self.execute(command, {
File "/usr/local/lib/python3.8/dist-packages/selenium/webdriver/remote/webdriver.py", line 321, in execute
self.error_handler.check_response(response)
File "/usr/local/lib/python3.8/dist-packages/selenium/webdriver/remote/errorhandler.py", line 242, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.JavascriptException: Message: TypeError: window.__additionalData[Object.keys(...)] is undefined

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "firsttry.py", line 77, in
session.like_by_tags(hashtags, amount=10, use_random_tags=True)
File "/usr/lib/python3.8/contextlib.py", line 131, in __exit__
self.gen.throw(type, value, traceback)
File "/usr/local/lib/python3.8/dist-packages/instapy/util.py", line 1971, in smart_run
session.end(threaded_session=threaded)
File "/usr/local/lib/python3.8/dist-packages/instapy/instapy.py", line 4497, in end
close_browser(self.browser, threaded_session, self.logger)
File "/usr/local/lib/python3.8/dist-packages/instapy/browser.py", line 186, in close_browser
with interruption_handler(threaded=threaded_session):
AttributeError: __enter__`

## Possible Solution (optional)

## InstaPy configuration

every script i tried!

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.