Skip to content

Two-factor authentication issue? RuntimeError: Tried 5 times to log in; all failed. #28

Open
@jkc120

Description

@jkc120

Issue

I believe the issue is either two-factor authentication and/or captcha tripping up the script.

Version

xfinity-usage 3.0.1 https://github.com/jantman/xfinity-usage

Installation Method

Ubuntu 16.04.2 LTS, pip2 install xfinity-usage

Supporting Software Versions

  • Python 2.7.12
  • The program 'virtualenv' is currently not installed. You can install it by typing:
    apt install virtualenv
  • selenium==3.141.0

Actual Output

[2020-01-30 17:03:59,902 ERROR] Screenshot saved to: /home/user/t/xfinity-usage/webdriver_fail.png
[2020-01-30 17:03:59,907 ERROR] Page title: Sign in to Xfinity
[2020-01-30 17:03:59,925 ERROR] Page source saved to: /home/user/t/xfinity-usage/webdriver_fail.html
[2020-01-30 17:03:59,925 WARNING] Exception while logging in
Traceback (most recent call last):
File "/home/user/.local/lib/python2.7/site-packages/xfinity_usage/xfinity_usage.py", line 234, in get_usage_page
self.get_usage_page(count=(count + 1))
File "/home/user/.local/lib/python2.7/site-packages/xfinity_usage/xfinity_usage.py", line 230, in get_usage_page
raise RuntimeError("Tried 5 times to log in; all failed.")
RuntimeError: Tried 5 times to log in; all failed.
[2020-01-30 17:04:30,650 ERROR] Error getting usage JSON; falling back to scraping page
snip

Expected Output

Data from the script, right now it can't login due to 2FA on the Xfinity web site sending me a code via SMS.

Testing Assistance

Would be glad to help!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions