tripleee / sloshy

Sloshy the Thawman, a simple chatbot to keep rooms alive on Stack Overflow / Stack Exchange
6 stars 11 forks source link

Nightly #191 failed: chatexchange.browser.LoginError: fkey input not found #24

Closed tripleee closed 1 year ago

tripleee commented 2 years ago

https://github.com/tripleee/sloshy/runs/4542329469?check_suite_focus=true traceback:

Run pip3 install -r requirements.txt
Requirement already satisfied: requests in /usr/lib/python3/dist-packages (from -r requirements.txt (line 1)) (2.22.0)
Collecting BeautifulSoup4
  Downloading beautifulsoup4-4.10.0-py3-none-any.whl (97 kB)
Collecting ChatExchange
  Downloading ChatExchange-0.0.4-py3-none-any.whl (17 kB)
Requirement already satisfied: PyYAML in /usr/lib/python3/dist-packages (from -r requirements.txt (line 4)) (5.3.1)
Collecting soupsieve>1.2
  Downloading soupsieve-2.3.1-py3-none-any.whl (37 kB)
Collecting epydoc>=3.0.1
  Downloading epydoc-3.0.1.tar.gz (1.8 MB)
Collecting pytest-timeout>=0.3
  Downloading pytest_timeout-2.0.2-py3-none-any.whl (11 kB)
Collecting bpython>=0.16
  Downloading bpython-0.22.1-py3-none-any.whl (187 kB)
Collecting websocket-client>=0.13.0
  Downloading websocket_client-1.2.3-py3-none-any.whl (53 kB)
Collecting httmock>=1.2.2
  Downloading httmock-1.4.0-py3-none-any.whl (4.8 kB)
Collecting pytest>=3.4.2
  Downloading pytest-6.2.5-py3-none-any.whl (280 kB)
Collecting coverage>=4.5.0
  Downloading coverage-6.2-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl (217 kB)
Collecting py>=1.5.0
  Downloading py-1.11.0-py2.py3-none-any.whl (98 kB)
Collecting cwcwidth
  Downloading cwcwidth-0.1.5-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl (56 kB)
Collecting typing-extensions
  Downloading typing_extensions-4.0.1-py3-none-any.whl (22 kB)
Collecting greenlet
  Downloading greenlet-1.1.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (156 kB)
Collecting pyxdg
  Downloading pyxdg-0.27-py2.py3-none-any.whl (49 kB)
Requirement already satisfied: pygments in /usr/lib/python3/dist-packages (from bpython>=0.16->ChatExchange->-r requirements.txt (line 3)) (2.3.1)
Collecting curtsies>=0.3.5
  Downloading curtsies-0.3.10.tar.gz (53 kB)
  Installing build dependencies: started
  Installing build dependencies: finished with status 'done'
  Getting requirements to build wheel: started
  Getting requirements to build wheel: finished with status 'done'
    Preparing wheel metadata: started
    Preparing wheel metadata: finished with status 'done'
Collecting iniconfig
  Downloading iniconfig-1.1.1-py2.py3-none-any.whl (5.0 kB)
Requirement already satisfied: packaging in /usr/local/lib/python3.8/dist-packages (from pytest>=3.4.2->ChatExchange->-r requirements.txt (line 3)) (21.3)
Collecting toml
  Downloading toml-0.10.2-py2.py3-none-any.whl (16 kB)
Requirement already satisfied: attrs>=19.2.0 in /usr/lib/python3/dist-packages (from pytest>=3.4.2->ChatExchange->-r requirements.txt (line 3)) (19.3.0)
Collecting pluggy<2.0,>=0.12
  Downloading pluggy-1.0.0-py2.py3-none-any.whl (13 kB)
Collecting blessings>=1.5
  Downloading blessings-1.7-py3-none-any.whl (18 kB)
Requirement already satisfied: pyparsing!=3.0.5,>=2.0.2 in /usr/local/lib/python3.8/dist-packages (from packaging->pytest>=3.4.2->ChatExchange->-r requirements.txt (line 3)) (3.0.6)
Requirement already satisfied: six in /usr/lib/python3/dist-packages (from blessings>=1.5->curtsies>=0.3.5->bpython>=0.16->ChatExchange->-r requirements.txt (line 3)) (1.14.0)
Building wheels for collected packages: epydoc, curtsies
  Building wheel for epydoc (setup.py): started
  Building wheel for epydoc (setup.py): finished with status 'done'
  Created wheel for epydoc: filename=epydoc-3.0.1-py3-none-any.whl size=263123 sha256=88b079e3443a97ef9a7244dc99e550b7f659a1765d060634c9ef786773d2e754
  Stored in directory: /home/runner/.cache/pip/wheels/d0/b4/cb/16cc3a7360deaaecb525dfc03773de410f3e198eb30f960339
  Building wheel for curtsies (PEP 517): started
  Building wheel for curtsies (PEP 517): finished with status 'done'
  Created wheel for curtsies: filename=curtsies-0.3.10-py3-none-any.whl size=35214 sha256=8eaac7cbbb7af3d056bdb2c846dd4f2e763130b59b885071e73aed1d3c31d036
  Stored in directory: /home/runner/.cache/pip/wheels/a1/0f/4f/de77186ff09b24a685ba38446eec050cbc18505474117325e6
Successfully built epydoc curtsies
Installing collected packages: soupsieve, BeautifulSoup4, epydoc, py, iniconfig, toml, pluggy, pytest, pytest-timeout, cwcwidth, typing-extensions, greenlet, pyxdg, blessings, curtsies, bpython, websocket-client, httmock, coverage, ChatExchange
Successfully installed BeautifulSoup4-4.10.0 ChatExchange-0.0.4 blessings-1.7 bpython-0.22.1 coverage-6.2 curtsies-0.3.10 cwcwidth-0.1.5 epydoc-3.0.1 greenlet-1.1.2 httmock-1.4.0 iniconfig-1.1.1 pluggy-1.0.0 py-1.11.0 pytest-6.2.5 pytest-timeout-2.0.2 pyxdg-0.27 soupsieve-2.3.1 toml-0.10.2 typing-extensions-4.0.1 websocket-client-1.2.3
Traceback (most recent call last):
  File "./run.py", line 18, in <module>
    Sloshy("sloshy.yaml").perform_scan("nightly run")
  File "/home/runner/work/sloshy/sloshy/sloshy.py", line 327, in perform_scan
    self.scan_rooms(startup_message)
  File "/home/runner/work/sloshy/sloshy/sloshy.py", line 290, in scan_rooms
    self.send_chat_message(
  File "/home/runner/work/sloshy/sloshy/sloshy.py", line 251, in send_chat_message
    room.send_message(message)
  File "/home/runner/work/sloshy/sloshy/sloshy.py", line 138, in send_message
    chat = self.clients.get_client_for_server(self.server)
  File "/home/runner/work/sloshy/sloshy/sloshy.py", line 91, in get_client_for_server
    client.login(self.email, self.password)
  File "/home/runner/.local/lib/python3.8/site-packages/chatexchange/client.py", line 138, in login
    self._br.login_site(self.host, email, password)
  File "/home/runner/.local/lib/python3.8/site-packages/chatexchange/browser.py", line 148, in login_site
    self._se_openid_login_with_fkey(
  File "/home/runner/.local/lib/python3.8/site-packages/chatexchange/browser.py", line 173, in _se_openid_login_with_fkey
    raise LoginError("fkey input not found")
chatexchange.browser.LoginError: fkey input not found
tripleee commented 1 year ago

Calling this a random glitch, no repro

secemp9 commented 12 months ago

Just FYI, but the same error is handled in SmokeyDetector, which might be worth looking into: https://github.com/Charcoal-SE/SmokeDetector/blob/master/chatcommunicate.py#L140

tripleee commented 11 months ago

Thanks for the pointer. I'm obviously familiar with SmokeDetector but I didn't want to complicate the code for uncertain gains. The system is already designed with some margins so that retrying the next nightly run is sufficient and robust enough.