-
Notifications
You must be signed in to change notification settings - Fork 104
Open
Description
Summary / 概要
I am trying to login using oj login https://codeforces.com/ which results in 403 Client error [ERROR] 403 Client Error: Forbidden for url: https://codeforces.com/enter
I tried to use cookie.jar file. I entered my credentials there but it has no effect.
Steps to reproduce / 再現方法
environments:
- I am using Git Bash (mingw64) on Windows 10
- $ oj --version
online-judge-tools 11.5.1 (+ online-judge-api-client 10.10.1)
Expected behavior / 期待される挙動
I assume it should open the browser (or command line) where I can enter credentials
Actual behavior / 実際の挙動
$ oj login https://codeforces.com/
[INFO] online-judge-tools 11.5.1 (+ online-judge-api-client 10.10.1)
[INFO] load cookie from: C:\Users\ADMINVIVO\AppData\Local\online-judge-tools\online-judge-tools\cookie.jar
[NETWORK] GET: https://codeforces.com/enter
[NETWORK] 403 Forbidden
[ERROR] 403 Client Error: Forbidden for url: https://codeforces.com/enter
Traceback (most recent call last):
File "C:\Program Files\Python313\Lib\site-packages\onlinejudge_command\main.py", line 101, in main
sys.exit(run_program(parsed, parser=parser))
~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Program Files\Python313\Lib\site-packages\onlinejudge_command\main.py", line 64, in run_program
if not subcommand_login.run(args):
~~~~~~~~~~~~~~~~~~~~^^^^^^
File "C:\Program Files\Python313\Lib\site-packages\onlinejudge_command\subcommand\login.py", line 175, in run
if is_logged_in_with_message(service, session=session):
~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Program Files\Python313\Lib\site-packages\onlinejudge_command\subcommand\login.py", line 156, in is_logged_in_with_message
if service.is_logged_in(session=session):
~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
File "C:\Users\ADMINVIVO\AppData\Roaming\Python\Python313\site-packages\onlinejudge\service\codeforces.py", line 65, in is_logged_in
resp = utils.request('GET', url, session=session, allow_redirects=False)
File "C:\Users\ADMINVIVO\AppData\Roaming\Python\Python313\site-packages\onlinejudge\_implementation\utils.py", line 182, in request
resp.raise_for_status()
~~~~~~~~~~~~~~~~~~~~~^^
File "C:\Program Files\Python313\Lib\site-packages\requests\models.py", line 1026, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 403 Client Error: Forbidden for url: https://codeforces.com/enter
Other notes / その他
- Will you try to create a pull request?
- no
koba-e964
Metadata
Metadata
Assignees
Labels
No labels