jdholtz / auto-southwest-check-in

A Python script that automatically checks in to your Southwest flight 24 hours beforehand.
GNU General Public License v3.0
458 stars 87 forks source link

Exception: Element {button#login-btn} was still visible after 5 seconds! #220

Closed KWottrich closed 9 months ago

KWottrich commented 9 months ago

Version

Auto-Southwest Check-In v7.1

Browser Version

Session info: chrome=117.0.5938.62

Description

Docker container is failing upon startup, see logs below

To Reproduce

  1. Pull latest image from https://hub.docker.com/r/jdholtz/auto-southwest-check-in
  2. Run docker image

Expected Behavior

The container starts normally

Relevant logs and program output

southwest-checkin  | Process Process-1:
southwest-checkin  | Traceback (most recent call last):
southwest-checkin  |   File "/app/lib/webdriver.py", line 184, in _click_login_button
southwest-checkin  |     seleniumbase_actions.wait_for_element_not_visible(driver, login_button, timeout=5)
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/seleniumbase/fixtures/page_actions.py", line 1030, in wait_for_element_not_visible
southwest-checkin  |     timeout_exception(Exception, message)
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/seleniumbase/fixtures/page_actions.py", line 266, in timeout_exception
southwest-checkin  |     raise exc(msg)
southwest-checkin  | Exception: Element {button#login-btn} was still visible after 5 seconds!
southwest-checkin  |
southwest-checkin  | During handling of the above exception, another exception occurred:
southwest-checkin  |
southwest-checkin  | Traceback (most recent call last):
southwest-checkin  |   File "/usr/local/lib/python3.12/multiprocessing/process.py", line 314, in _bootstrap
southwest-checkin  |     self.run()
southwest-checkin  |   File "/usr/local/lib/python3.12/multiprocessing/process.py", line 108, in run
southwest-checkin  |     self._target(*self._args, **self._kwargs)
southwest-checkin  |   File "/app/lib/reservation_monitor.py", line 42, in monitor
southwest-checkin  |     self._monitor()
southwest-checkin  |   File "/app/lib/reservation_monitor.py", line 157, in _monitor
southwest-checkin  |     reservations, skip_scheduling = self._get_reservations()
southwest-checkin  |                                     ^^^^^^^^^^^^^^^^^^^^^^^^
southwest-checkin  |   File "/app/lib/reservation_monitor.py", line 182, in _get_reservations
southwest-checkin  |     reservations = webdriver.get_reservations(self)
southwest-checkin  |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
southwest-checkin  |   File "/app/lib/webdriver.py", line 93, in get_reservations
southwest-checkin  |     self._wait_for_login(driver, account_monitor)
southwest-checkin  |   File "/app/lib/webdriver.py", line 163, in _wait_for_login
southwest-checkin  |     self._click_login_button(driver)
southwest-checkin  |   File "/app/lib/webdriver.py", line 187, in _click_login_button
southwest-checkin  |     driver.click(login_button)
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/seleniumbase/core/sb_driver.py", line 54, in click
southwest-checkin  |     page_actions.click(self.driver, *args, **kwargs)
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/seleniumbase/fixtures/page_actions.py", line 1526, in click
southwest-checkin  |     element.click()
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/selenium/webdriver/remote/webelement.py", line 93, in click
southwest-checkin  |     self._execute(Command.CLICK_ELEMENT)
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/selenium/webdriver/remote/webelement.py", line 394, in _execute
southwest-checkin  |     return self._parent.execute(command, params)
southwest-checkin  |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/selenium/webdriver/remote/webdriver.py", line 347, in execute
southwest-checkin  |     self.error_handler.check_response(response)
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/selenium/webdriver/remote/errorhandler.py", line 229, in check_response
southwest-checkin  |     raise exception_class(message, screen, stacktrace)
southwest-checkin  | selenium.common.exceptions.ElementClickInterceptedException: Message: element click intercepted: Element <button class="mt4 button button--fluid larger button--yellow" type="submit" id="login-btn" role="submit">...</button> is not clickable at point (712, 311). Other element would receive the click: <div class="backdrop visible active"></div>
southwest-checkin  |   (Session info: chrome=117.0.5938.62)
southwest-checkin  |
southwest-checkin  | Process Process-2:
southwest-checkin  | Traceback (most recent call last):
southwest-checkin  |   File "/app/lib/webdriver.py", line 184, in _click_login_button
southwest-checkin  |     seleniumbase_actions.wait_for_element_not_visible(driver, login_button, timeout=5)
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/seleniumbase/fixtures/page_actions.py", line 1030, in wait_for_element_not_visible
southwest-checkin  |     timeout_exception(Exception, message)
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/seleniumbase/fixtures/page_actions.py", line 266, in timeout_exception
southwest-checkin  |     raise exc(msg)
southwest-checkin  | Exception: Element {button#login-btn} was still visible after 5 seconds!
southwest-checkin  |
southwest-checkin  | During handling of the above exception, another exception occurred:
southwest-checkin  |
southwest-checkin  | Traceback (most recent call last):
southwest-checkin  |   File "/usr/local/lib/python3.12/multiprocessing/process.py", line 314, in _bootstrap
southwest-checkin  |     self.run()
southwest-checkin  |   File "/usr/local/lib/python3.12/multiprocessing/process.py", line 108, in run
southwest-checkin  |     self._target(*self._args, **self._kwargs)
southwest-checkin  |   File "/app/lib/reservation_monitor.py", line 42, in monitor
southwest-checkin  |     self._monitor()
southwest-checkin  |   File "/app/lib/reservation_monitor.py", line 157, in _monitor
southwest-checkin  |     reservations, skip_scheduling = self._get_reservations()
southwest-checkin  |                                     ^^^^^^^^^^^^^^^^^^^^^^^^
southwest-checkin  |   File "/app/lib/reservation_monitor.py", line 182, in _get_reservations
southwest-checkin  |     reservations = webdriver.get_reservations(self)
southwest-checkin  |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
southwest-checkin  |   File "/app/lib/webdriver.py", line 93, in get_reservations
southwest-checkin  |     self._wait_for_login(driver, account_monitor)
southwest-checkin  |   File "/app/lib/webdriver.py", line 163, in _wait_for_login
southwest-checkin  |     self._click_login_button(driver)
southwest-checkin  |   File "/app/lib/webdriver.py", line 187, in _click_login_button
southwest-checkin  |     driver.click(login_button)
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/seleniumbase/core/sb_driver.py", line 54, in click
southwest-checkin  |     page_actions.click(self.driver, *args, **kwargs)
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/seleniumbase/fixtures/page_actions.py", line 1526, in click
southwest-checkin  |     element.click()
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/selenium/webdriver/remote/webelement.py", line 93, in click
southwest-checkin  |     self._execute(Command.CLICK_ELEMENT)
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/selenium/webdriver/remote/webelement.py", line 394, in _execute
southwest-checkin  |     return self._parent.execute(command, params)
southwest-checkin  |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/selenium/webdriver/remote/webdriver.py", line 347, in execute
southwest-checkin  |     self.error_handler.check_response(response)
southwest-checkin  |   File "/usr/local/lib/python3.12/site-packages/selenium/webdriver/remote/errorhandler.py", line 229, in check_response
southwest-checkin  |     raise exception_class(message, screen, stacktrace)
southwest-checkin  | selenium.common.exceptions.ElementClickInterceptedException: Message: element click intercepted: Element <button class="mt4 button button--fluid larger button--yellow" type="submit" id="login-btn" role="submit">...</button> is not clickable at point (712, 311). Other element would receive the click: <div class="backdrop visible active"></div>
southwest-checkin  |   (Session info: chrome=117.0.5938.62)
southwest-checkin  |
southwest-checkin exited with code 0

Additional context

This my docker-compose:

version: "3"
services:
  southwest-checkin:
    image: jdholtz/auto-southwest-check-in
    container_name: southwest-checkin
    volumes:
      - /srv/southwest-checkin/config.json:/app/config.json
    restart: unless-stopped

And this is my config.json:

{
    "check_fares": true,
    "notification_urls": "",
    "notification_level": 2,
    "retrieval_interval": 24,
    "accounts": [
        {"username": "MYUSER1", "password": "MYPASSWORD1"},
        {"username": "MYUSER2", "password": "MYPASSWORD2"}
    ],
    "reservations": []
}
jdholtz commented 9 months ago

This is a duplicate of #208, #217, and #215 which are ultimately a duplicate of https://github.com/jdholtz/auto-southwest-check-in/issues/201. The exception has already been fixed in the develop Docker image, but the underlying issue is a Too Many Requests error.