diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 25f90948..a2ed40cf 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -48,7 +48,7 @@ jobs:
run: make tests
- name: Upload coverage to Codecov
- uses: codecov/codecov-action@v4
+ uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ${{github.workspace}}/coverage/coverage.xml
diff --git a/README.md b/README.md
index 524ccd93..992af9d7 100644
--- a/README.md
+++ b/README.md
@@ -4,7 +4,7 @@
### [Capsolver](https://www.capsolver.com/?utm_source=github&utm_medium=repo&utm_campaign=scraping&utm_term=python-rucaptcha)
-[![Capsolver](files/capsolver.png)](https://www.capsolver.com/?utm_source=github&utm_medium=repo&utm_campaign=scraping&utm_term=python-rucaptcha)
+[![Capsolver](files/capsolver.jpg)](https://www.capsolver.com/?utm_source=github&utm_medium=repo&utm_campaign=scraping&utm_term=python-rucaptcha)
diff --git a/docs/_static/capsolver.jpg b/docs/_static/capsolver.jpg
new file mode 100644
index 00000000..dafb9ca4
Binary files /dev/null and b/docs/_static/capsolver.jpg differ
diff --git a/docs/_static/capsolver.png b/docs/_static/capsolver.png
deleted file mode 100644
index 6f5b3bdf..00000000
Binary files a/docs/_static/capsolver.png and /dev/null differ
diff --git a/docs/conf.py b/docs/conf.py
index bfe4c0ab..aa8a3722 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -32,7 +32,9 @@
# -- Project information -----------------------------------------------------
project = "python-rucaptcha"
-copyright = f"{date.today().year}, AndreiDrang; Release - {__version__}; Last update - {date.today()}"
+copyright = (f"{date.today().year}, " +
+ f"AndreiDrang; Release - {__version__};" +
+ f"Last update - {date.today()}")
author = "AndreiDrang"
# -- General configuration ---------------------------------------------------
diff --git a/docs/modules/main/info.md b/docs/modules/main/info.md
index fb46a846..4d419719 100644
--- a/docs/modules/main/info.md
+++ b/docs/modules/main/info.md
@@ -5,7 +5,7 @@
### [Capsolver](https://www.capsolver.com/?utm_source=github&utm_medium=repo&utm_campaign=scraping&utm_term=python-rucaptcha)
-[![Capsolver](../../_static/capsolver.png)](https://www.capsolver.com/?utm_source=github&utm_medium=repo&utm_campaign=scraping&utm_term=python-rucaptcha)
+[![Capsolver](../../_static/capsolver.jpg)](https://www.capsolver.com/?utm_source=github&utm_medium=repo&utm_campaign=scraping&utm_term=python-rucaptcha)
diff --git a/docs/requirements.txt b/docs/requirements.txt
index b415756b..bda59f06 100644
--- a/docs/requirements.txt
+++ b/docs/requirements.txt
@@ -1,9 +1,9 @@
sphinx==8.1.3
-pallets_sphinx_themes==2.1.3
+pallets_sphinx_themes==2.3.0
myst-parser==4.0.0
autodoc_pydantic==2.2.0
-pydantic==2.9.2
-pydantic-settings==2.5.2
+pydantic==2.10.2
+pydantic-settings==2.6.1
enum-tools[sphinx]==0.12.0
requests>=2.32.0 # not directly required, pinned by Snyk to avoid a vulnerability
urllib3>=2.2.2 # not directly required, pinned by Snyk to avoid a vulnerability
diff --git a/files/capsolver.jpg b/files/capsolver.jpg
new file mode 100644
index 00000000..dafb9ca4
Binary files /dev/null and b/files/capsolver.jpg differ
diff --git a/files/capsolver.png b/files/capsolver.png
deleted file mode 100644
index 6f5b3bdf..00000000
Binary files a/files/capsolver.png and /dev/null differ
diff --git a/src/python_rucaptcha/__version__.py b/src/python_rucaptcha/__version__.py
index 063175c6..ca0d9d35 100644
--- a/src/python_rucaptcha/__version__.py
+++ b/src/python_rucaptcha/__version__.py
@@ -1 +1 @@
-__version__ = "6.2"
+__version__ = "6.3"
diff --git a/src/python_rucaptcha/amazon_waf.py b/src/python_rucaptcha/amazon_waf.py
index eddc6623..1b35957c 100644
--- a/src/python_rucaptcha/amazon_waf.py
+++ b/src/python_rucaptcha/amazon_waf.py
@@ -77,7 +77,8 @@ def __init__(
# check user params
if method not in AmazonWAFCaptchaEnm.list_values():
- raise ValueError(f"Invalid method parameter set, available - {AmazonWAFCaptchaEnm.list_values()}")
+ raise ValueError(
+ f"Invalid method parameter set, available - {AmazonWAFCaptchaEnm.list_values()}")
# insert `gt` param to payload
self.create_task_payload["task"].update(
{
diff --git a/src/python_rucaptcha/capy_puzzle.py b/src/python_rucaptcha/capy_puzzle.py
index e1de1e82..75a9dfc7 100644
--- a/src/python_rucaptcha/capy_puzzle.py
+++ b/src/python_rucaptcha/capy_puzzle.py
@@ -103,11 +103,13 @@ def __init__(
"""
super().__init__(method=method, *args, **kwargs)
- self.create_task_payload["task"].update({"websiteURL": websiteURL, "websiteKey": websiteKey})
+ self.create_task_payload["task"].update({"websiteURL": websiteURL,
+ "websiteKey": websiteKey})
# check user params
if method not in CapyPuzzleEnm.list_values():
- raise ValueError(f"Invalid method parameter set, available - {CapyPuzzleEnm.list_values()}")
+ raise ValueError(
+ f"Invalid method parameter set, available - {CapyPuzzleEnm.list_values()}")
def captcha_handler(self, **kwargs) -> dict:
"""
diff --git a/src/python_rucaptcha/cutcaptcha.py b/src/python_rucaptcha/cutcaptcha.py
index 8be9a152..7f1e3a7f 100644
--- a/src/python_rucaptcha/cutcaptcha.py
+++ b/src/python_rucaptcha/cutcaptcha.py
@@ -81,11 +81,14 @@ def __init__(
"""
super().__init__(method=method, *args, **kwargs)
- self.create_task_payload["task"].update({"websiteURL": websiteURL, "miseryKey": miseryKey, "apiKey": apiKey})
+ self.create_task_payload["task"].update({"websiteURL": websiteURL,
+ "miseryKey": miseryKey,
+ "apiKey": apiKey})
# check user params
if method not in CutCaptchaEnm.list_values():
- raise ValueError(f"Invalid method parameter set, available - {CutCaptchaEnm.list_values()}")
+ raise ValueError(
+ f"Invalid method parameter set, available - {CutCaptchaEnm.list_values()}")
def captcha_handler(self, **kwargs) -> dict:
"""
diff --git a/src/python_rucaptcha/datadome_captcha.py b/src/python_rucaptcha/datadome_captcha.py
index 1da0bc87..095ee864 100644
--- a/src/python_rucaptcha/datadome_captcha.py
+++ b/src/python_rucaptcha/datadome_captcha.py
@@ -20,8 +20,10 @@ def __init__(
Args:
rucaptcha_key: User API key
websiteURL: Full URL of the captcha page
- captchaUrl: The value of the `src` parameter for the `iframe` element containing the captcha on the page.
- userAgent: User-Agent of your browser will be used to load the captcha. Use only modern browser's User-Agents
+ captchaUrl: The value of the `src` parameter for the `iframe` element
+ containing the captcha on the page.
+ userAgent: User-Agent of your browser will be used to load the captcha.
+ Use only modern browser's User-Agents
proxyType: Proxy type - `http`, `socks4`, `socks5`
proxyAddress: Proxy IP address or hostname
proxyPort: Proxy port
diff --git a/src/python_rucaptcha/hcaptcha.py b/src/python_rucaptcha/hcaptcha.py
index 25aadb8c..22dcbfc2 100644
--- a/src/python_rucaptcha/hcaptcha.py
+++ b/src/python_rucaptcha/hcaptcha.py
@@ -76,11 +76,13 @@ def __init__(
"""
super().__init__(method=method, *args, **kwargs)
- self.create_task_payload["task"].update({"websiteURL": websiteURL, "websiteKey": websiteKey})
+ self.create_task_payload["task"].update({"websiteURL": websiteURL,
+ "websiteKey": websiteKey})
# check user params
if method not in HCaptchaEnm.list_values():
- raise ValueError(f"Invalid method parameter set, available - {HCaptchaEnm.list_values()}")
+ raise ValueError(
+ f"Invalid method parameter set, available - {HCaptchaEnm.list_values()}")
def captcha_handler(self, **kwargs) -> dict:
"""
diff --git a/src/python_rucaptcha/key_captcha.py b/src/python_rucaptcha/key_captcha.py
index 28a31d1d..f4c609a7 100644
--- a/src/python_rucaptcha/key_captcha.py
+++ b/src/python_rucaptcha/key_captcha.py
@@ -80,7 +80,8 @@ def __init__(
# check user params
if method not in KeyCaptchaEnm.list_values():
- raise ValueError(f"Invalid method parameter set, available - {KeyCaptchaEnm.list_values()}")
+ raise ValueError(
+ f"Invalid method parameter set, available - {KeyCaptchaEnm.list_values()}")
def captcha_handler(self, **kwargs) -> dict:
"""
diff --git a/src/python_rucaptcha/lemin_captcha.py b/src/python_rucaptcha/lemin_captcha.py
index 0c637db9..bd133246 100644
--- a/src/python_rucaptcha/lemin_captcha.py
+++ b/src/python_rucaptcha/lemin_captcha.py
@@ -78,11 +78,14 @@ def __init__(
"""
super().__init__(method=method, *args, **kwargs)
- self.create_task_payload["task"].update({"websiteURL": websiteURL, "captchaId": captchaId, "div_id": div_id})
+ self.create_task_payload["task"].update({"websiteURL": websiteURL,
+ "captchaId": captchaId,
+ "div_id": div_id})
# check user params
if method not in LeminCaptchaEnm.list_values():
- raise ValueError(f"Invalid method parameter set, available - {LeminCaptchaEnm.list_values()}")
+ raise ValueError(
+ f"Invalid method parameter set, available - {LeminCaptchaEnm.list_values()}")
def captcha_handler(self, **kwargs) -> dict:
"""
diff --git a/src/python_rucaptcha/mt_captcha.py b/src/python_rucaptcha/mt_captcha.py
index 25b6a43f..ed208ed2 100644
--- a/src/python_rucaptcha/mt_captcha.py
+++ b/src/python_rucaptcha/mt_captcha.py
@@ -70,10 +70,12 @@ def __init__(
"""
super().__init__(method=method, *args, **kwargs)
- self.create_task_payload["task"].update({"websiteURL": websiteURL, "websiteKey": websiteKey})
+ self.create_task_payload["task"].update({"websiteURL": websiteURL,
+ "websiteKey": websiteKey})
# check user params
if method not in MTCaptchaEnm.list_values():
- raise ValueError(f"Invalid method parameter set, available - {MTCaptchaEnm.list_values()}")
+ raise ValueError(
+ f"Invalid method parameter set, available - {MTCaptchaEnm.list_values()}")
def captcha_handler(self, **kwargs) -> dict:
"""
diff --git a/src/python_rucaptcha/re_captcha.py b/src/python_rucaptcha/re_captcha.py
index 2ecfbada..0204974c 100644
--- a/src/python_rucaptcha/re_captcha.py
+++ b/src/python_rucaptcha/re_captcha.py
@@ -142,7 +142,8 @@ def __init__(
# check user params
if method not in ReCaptchaEnm.list_values():
- raise ValueError(f"Invalid method parameter set, available - {ReCaptchaEnm.list_values()}")
+ raise ValueError(
+ f"Invalid method parameter set, available - {ReCaptchaEnm.list_values()}")
def captcha_handler(self, **kwargs) -> dict:
"""
diff --git a/src/python_rucaptcha/rotate_captcha.py b/src/python_rucaptcha/rotate_captcha.py
index 25f2568d..17f5df1a 100644
--- a/src/python_rucaptcha/rotate_captcha.py
+++ b/src/python_rucaptcha/rotate_captcha.py
@@ -74,7 +74,8 @@ def __init__(
}
>>> await RotateCaptcha(rucaptcha_key="aa9011f31111181111168611f1151122",
- ... angle=45).aio_captcha_handler(captcha_file="examples/rotate/rotate_ex.png")
+ ... angle=45).aio_captcha_handler(
+ ... captcha_file="examples/rotate/rotate_ex.png")
{
"errorId":0,
"status":"ready",
diff --git a/src/python_rucaptcha/tencent.py b/src/python_rucaptcha/tencent.py
index 208f7f9b..3cadc275 100644
--- a/src/python_rucaptcha/tencent.py
+++ b/src/python_rucaptcha/tencent.py
@@ -19,7 +19,8 @@ def __init__(
Args:
rucaptcha_key: User API key
websiteURL: The full URL of target web page where the captcha is loaded.
- We do not open the page, not a problem if it is available only for authenticated users
+ We do not open the page, not a problem if it is available
+ only for authenticated users
appId: The value of `appId` parameter in the website source code.
method: Captcha type
@@ -81,7 +82,8 @@ def __init__(
# check user params
if method not in TencentEnm.list_values():
- raise ValueError(f"Invalid method parameter set, available - {TencentEnm.list_values()}")
+ raise ValueError(
+ f"Invalid method parameter set, available - {TencentEnm.list_values()}")
def captcha_handler(self, **kwargs) -> dict:
"""
diff --git a/src/python_rucaptcha/turnstile.py b/src/python_rucaptcha/turnstile.py
index a1aa3786..cbf62888 100644
--- a/src/python_rucaptcha/turnstile.py
+++ b/src/python_rucaptcha/turnstile.py
@@ -81,7 +81,8 @@ def __init__(
# check user params
if method not in TurnstileCaptchaEnm.list_values():
- raise ValueError(f"Invalid method parameter set, available - {TurnstileCaptchaEnm.list_values()}")
+ raise ValueError(
+ f"Invalid method parameter set, available - {TurnstileCaptchaEnm.list_values()}")
def captcha_handler(self, **kwargs) -> dict:
"""