From ba37572bcbb8a03b8536bf276334a253270cc42f Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 8 Nov 2022 20:53:04 +0300 Subject: [PATCH 01/12] Create example.rst --- docs/modules/gee-test/example.rst | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 docs/modules/gee-test/example.rst diff --git a/docs/modules/gee-test/example.rst b/docs/modules/gee-test/example.rst new file mode 100644 index 00000000..998e9d58 --- /dev/null +++ b/docs/modules/gee-test/example.rst @@ -0,0 +1,12 @@ +GeeTest +======= + +To import this module: + +.. code-block:: python + + from python3_captchaai.gee_test import GeeTest + + +.. autoclass:: gee_test.GeeTest + :members: \ No newline at end of file From 98921287d952452d544f686cb935b832fc48f83e Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 8 Nov 2022 20:53:06 +0300 Subject: [PATCH 02/12] Update index.rst --- docs/index.rst | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/index.rst b/docs/index.rst index 55421351..8ba72192 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -25,6 +25,7 @@ The library is intended for software developers and is used to work with the `Ca modules/image-to-text/example.rst modules/re-captcha/example.rst modules/h-captcha/example.rst + modules/gee-test/example.rst .. toctree:: :maxdepth: 2 From 238c33c907c1f0f171189b2fcc7bf52c1b5ef1f0 Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 8 Nov 2022 20:53:09 +0300 Subject: [PATCH 03/12] Update conf.py --- docs/conf.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/conf.py b/docs/conf.py index a718c71c..7059abd9 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -21,7 +21,7 @@ for x in os.walk("src/python3_captchaai/"): sys.path.insert(0, x[0]) -from python3_captchaai import core, hcaptcha, image_to_text, recaptcha +from python3_captchaai import core, hcaptcha, image_to_text, recaptcha, gee_test from python3_captchaai.__version__ import __version__ # -- Project information ----------------------------------------------------- From 06bde820d4967b094a9cf73ff3940bd4640f4892 Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 8 Nov 2022 20:58:21 +0300 Subject: [PATCH 04/12] Update example.rst --- docs/modules/h-captcha/example.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/modules/h-captcha/example.rst b/docs/modules/h-captcha/example.rst index efb2dc74..fde85140 100644 --- a/docs/modules/h-captcha/example.rst +++ b/docs/modules/h-captcha/example.rst @@ -1,5 +1,5 @@ HCaptcha -============= +======== To import this module: From 12d0dd67cbf843b12fc66d09886da473f996cd63 Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 8 Nov 2022 20:58:23 +0300 Subject: [PATCH 05/12] Update example.rst --- docs/modules/re-captcha/example.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/modules/re-captcha/example.rst b/docs/modules/re-captcha/example.rst index 9bcfda09..14b1f2f9 100644 --- a/docs/modules/re-captcha/example.rst +++ b/docs/modules/re-captcha/example.rst @@ -1,5 +1,5 @@ ReCaptcha -============= +========= To import this module: From 6bd4f916b0b6e5a908d6643fc5a7bc5bb0aab307 Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 8 Nov 2022 20:58:25 +0300 Subject: [PATCH 06/12] Update gee_test.py --- src/python3_captchaai/gee_test.py | 37 ++++++++++++++----------------- 1 file changed, 17 insertions(+), 20 deletions(-) diff --git a/src/python3_captchaai/gee_test.py b/src/python3_captchaai/gee_test.py index 6116f75f..d7c2a9fc 100644 --- a/src/python3_captchaai/gee_test.py +++ b/src/python3_captchaai/gee_test.py @@ -24,8 +24,7 @@ class BaseGeeTest(BaseCaptcha): request_url: API address for sending requests Examples: - >>> GeeTest( - ... api_key="CAI-1324...", + >>> GeeTest(api_key="CAI-1324...", ... captcha_type="GeetestTaskProxyless", ... websiteURL="https://www.geetest.com/en/demo", ... gt="022397c99c9f646f6477822485f30404", @@ -95,15 +94,14 @@ def captcha_handler( Like ``coordinate``, ``enterprisePayload`` and etc. - more info in service docs Examples: - >>> GeeTest( - ... api_key="CAI-1324...", - ... captcha_type="GeetestTaskProxyless", - ... websiteURL="https://www.geetest.com/en/demo", - ... gt="022397c99c9f646f6477822485f30404", - ... ).captcha_handler( - ... challenge="a66f31a53a404af8d1f271eec5138aa1", - ... geetestApiServerSubdomain="api.geetest.com" - ... ) + >>> GeeTest(api_key="CAI-1324...", + ... captcha_type="GeetestTaskProxyless", + ... websiteURL="https://www.geetest.com/en/demo", + ... gt="022397c99c9f646f6477822485f30404", + ... ).captcha_handler( + ... challenge="a66f31a53a404af8d1f271eec5138aa1", + ... geetestApiServerSubdomain="api.geetest.com" + ... ) CaptchaResponseSer(errorId=False errorCode=None errorDescription=None @@ -138,15 +136,14 @@ async def aio_captcha_handler( Like ``coordinate``, ``enterprisePayload`` and etc. - more info in service docs Examples: - >>> await GeeTest( - ... api_key="CAI-1324...", - ... captcha_type="GeetestTaskProxyless", - ... websiteURL="https://www.geetest.com/en/demo", - ... gt="022397c99c9f646f6477822485f30404", - ... ).aio_captcha_handler( - ... challenge="a66f31a53a404af8d1f271eec5138aa1", - ... geetestApiServerSubdomain="api.geetest.com" - ... ) + >>> await GeeTest(api_key="CAI-1324...", + ... captcha_type="GeetestTaskProxyless", + ... websiteURL="https://www.geetest.com/en/demo", + ... gt="022397c99c9f646f6477822485f30404", + ... ).aio_captcha_handler( + ... challenge="a66f31a53a404af8d1f271eec5138aa1", + ... geetestApiServerSubdomain="api.geetest.com" + ... ) CaptchaResponseSer(errorId=False errorCode=None errorDescription=None From 0e418b9a55b1cf9e1e9f098154c1861c3c7c23f3 Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 8 Nov 2022 20:59:42 +0300 Subject: [PATCH 07/12] 0.0.8 --- src/python3_captchaai/__version__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/python3_captchaai/__version__.py b/src/python3_captchaai/__version__.py index 9eed420a..a73339bf 100644 --- a/src/python3_captchaai/__version__.py +++ b/src/python3_captchaai/__version__.py @@ -1 +1 @@ -__version__ = "0.0.7a" +__version__ = "0.0.8" From e821a65d85d9e8416cec74affc2b06cd97bbc9d6 Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 8 Nov 2022 21:01:19 +0300 Subject: [PATCH 08/12] Update setup.py --- src/setup.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/setup.py b/src/setup.py index af3e9dc1..8e31e74a 100644 --- a/src/setup.py +++ b/src/setup.py @@ -45,6 +45,9 @@ def finalize_options(self): pass def run(self): + logging.info("Clean builds . . .") + shutil.rmtree("dist/") + logging.info("Building Source and Wheel distribution . . .") os.system("python setup.py bdist_wheel") From d6c1a71f220eb42aff6b980ec89ba824cc7eb97c Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 8 Nov 2022 21:02:01 +0300 Subject: [PATCH 09/12] Update conf.py --- docs/conf.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/conf.py b/docs/conf.py index 7059abd9..2722ce3f 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -21,7 +21,8 @@ for x in os.walk("src/python3_captchaai/"): sys.path.insert(0, x[0]) -from python3_captchaai import core, hcaptcha, image_to_text, recaptcha, gee_test +from python3_captchaai import (core, gee_test, hcaptcha, image_to_text, + recaptcha) from python3_captchaai.__version__ import __version__ # -- Project information ----------------------------------------------------- From 82515362a0bebe12e893da68c5e7654d5fb67cde Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 8 Nov 2022 21:09:38 +0300 Subject: [PATCH 10/12] Update test.yml --- .github/workflows/test.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index d4e2baaa..4f5bfc82 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -47,6 +47,7 @@ jobs: - name: Upload coverage to Codecov uses: codecov/codecov-action@v3 with: + token: ${{ secrets.CODECOV_TOKEN }} files: /home/runner/work/python3-captchaai/python3-captchaai/src/coverage/coverage.xml fail_ci_if_error: true verbose: true From 89690a6ec8528e3d3e7af67a62be7d825f864657 Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 8 Nov 2022 22:54:40 +0300 Subject: [PATCH 11/12] Update info.md --- docs/modules/main/info.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/modules/main/info.md b/docs/modules/main/info.md index e335ab08..69dfd2ed 100644 --- a/docs/modules/main/info.md +++ b/docs/modules/main/info.md @@ -9,6 +9,7 @@ [![Downloads](https://pepy.tech/badge/python3-captchaai/month)](https://pepy.tech/project/python3-captchaai) [![Maintainability](https://api.codeclimate.com/v1/badges/3431fd3fe71baf7eb9da/maintainability)](https://codeclimate.com/github/AndreiDrang/python3-captchaai/maintainability) +[![Codacy Badge](https://app.codacy.com/project/badge/Grade/323d4eda0fe1477bbea8fe8902b9e97e)](https://www.codacy.com/gh/AndreiDrang/python3-captchaai/dashboard?utm_source=github.com&utm_medium=referral&utm_content=AndreiDrang/python3-captchaai&utm_campaign=Badge_Grade) [![codecov](https://codecov.io/gh/AndreiDrang/python3-captchaai/branch/main/graph/badge.svg?token=2L4VVIF4G8)](https://codecov.io/gh/AndreiDrang/python3-captchaai) [![Build check](https://github.com/AndreiDrang/python3-captchaai/actions/workflows/test_build.yml/badge.svg?branch=main)](https://github.com/AndreiDrang/python3-captchaai/actions/workflows/test_build.yml) From d303da682775b59956d65940b0b91804209f4065 Mon Sep 17 00:00:00 2001 From: Andrei Date: Tue, 8 Nov 2022 22:54:42 +0300 Subject: [PATCH 12/12] Update README.md --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 433ee2a6..1d5c268e 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,7 @@ [![Downloads](https://pepy.tech/badge/python3-captchaai/month)](https://pepy.tech/project/python3-captchaai) [![Maintainability](https://api.codeclimate.com/v1/badges/3431fd3fe71baf7eb9da/maintainability)](https://codeclimate.com/github/AndreiDrang/python3-captchaai/maintainability) +[![Codacy Badge](https://app.codacy.com/project/badge/Grade/323d4eda0fe1477bbea8fe8902b9e97e)](https://www.codacy.com/gh/AndreiDrang/python3-captchaai/dashboard?utm_source=github.com&utm_medium=referral&utm_content=AndreiDrang/python3-captchaai&utm_campaign=Badge_Grade) [![codecov](https://codecov.io/gh/AndreiDrang/python3-captchaai/branch/main/graph/badge.svg?token=2L4VVIF4G8)](https://codecov.io/gh/AndreiDrang/python3-captchaai) [![Build check](https://github.com/AndreiDrang/python3-captchaai/actions/workflows/test_build.yml/badge.svg?branch=main)](https://github.com/AndreiDrang/python3-captchaai/actions/workflows/test_build.yml)