Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.6 #30

Merged
merged 61 commits into from
Apr 28, 2023
Merged

0.6 #30

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
61 commits
Select commit Hold shift + click to select a range
9748f88
Update setup.py
AndreiDrang Mar 20, 2023
4b30437
Add files via upload
AndreiDrang Apr 25, 2023
c636a79
Delete -3612959692938013993.MP4
AndreiDrang Apr 25, 2023
50eddc2
Add files via upload
AndreiDrang Apr 25, 2023
43414cf
Delete 2938013993.mp4
AndreiDrang Apr 25, 2023
757c5c4
Add files via upload
AndreiDrang Apr 25, 2023
7922442
Update README.md
AndreiDrang Apr 26, 2023
e41028a
Update README.md
AndreiDrang Apr 26, 2023
a1d0a66
Update README.md
AndreiDrang Apr 27, 2023
6432d5b
Update README.md
AndreiDrang Apr 28, 2023
2c243bf
Update setup.py
AndreiDrang Apr 28, 2023
e547397
upd
AndreiDrang Apr 28, 2023
5e82bfb
rename
AndreiDrang Apr 28, 2023
d841049
Update Makefile
AndreiDrang Apr 28, 2023
9fbd32e
Update enum.py
AndreiDrang Apr 28, 2023
a66e896
Update base.py
AndreiDrang Apr 28, 2023
877af04
Update serializer.py
AndreiDrang Apr 28, 2023
4a49411
Update fun_captcha.py
AndreiDrang Apr 28, 2023
779061f
Update hcaptcha.py
AndreiDrang Apr 28, 2023
f564bf3
upd
AndreiDrang Apr 28, 2023
577a3f3
0.5.7
AndreiDrang Apr 28, 2023
f4c1367
Update README.md
AndreiDrang Apr 28, 2023
e5dfb93
Update README.md
AndreiDrang Apr 28, 2023
274ba83
Update build.yml
AndreiDrang Apr 28, 2023
8ffdc3a
Update install.yml
AndreiDrang Apr 28, 2023
0ac2334
Update lint.yml
AndreiDrang Apr 28, 2023
6af63d0
Update sphinx.yml
AndreiDrang Apr 28, 2023
c7179ca
Update requirements.style.txt
AndreiDrang Apr 28, 2023
22c67cc
Create pyproject.toml
AndreiDrang Apr 28, 2023
5d7e93f
Update Makefile
AndreiDrang Apr 28, 2023
7299f69
Delete pyproject.toml
AndreiDrang Apr 28, 2023
9651868
Update LICENSE
AndreiDrang Apr 28, 2023
20fd51e
Create .gitconfig
AndreiDrang Apr 28, 2023
8e61007
Update .gitignore
AndreiDrang Apr 28, 2023
7bad8bc
Update .coveragerc
AndreiDrang Apr 28, 2023
c6db433
Update conf.py
AndreiDrang Apr 28, 2023
87fb418
move tests
AndreiDrang Apr 28, 2023
1a25ba3
Update README.md
AndreiDrang Apr 28, 2023
09dd93d
Update enum.py
AndreiDrang Apr 28, 2023
82fcd81
Update serializer.py
AndreiDrang Apr 28, 2023
04cf1e0
Update mt_captcha.py
AndreiDrang Apr 28, 2023
c870c5c
Update recaptcha.py
AndreiDrang Apr 28, 2023
470ae0d
refactor
AndreiDrang Apr 28, 2023
6c9db8c
Update mt_captcha.py
AndreiDrang Apr 28, 2023
58962a6
Update datadome_slider.py
AndreiDrang Apr 28, 2023
637b0a7
Update datadome_slider.py
AndreiDrang Apr 28, 2023
1cf76b2
Update mt_captcha.py
AndreiDrang Apr 28, 2023
fe704ea
Create cloudflare.py
AndreiDrang Apr 28, 2023
8a8a33c
Update enum.py
AndreiDrang Apr 28, 2023
dc0643e
Update serializer.py
AndreiDrang Apr 28, 2023
be89b20
Update datadome_slider.py
AndreiDrang Apr 28, 2023
0d5abfc
refactor
AndreiDrang Apr 28, 2023
86f6d73
0.6
AndreiDrang Apr 28, 2023
e181455
Update sphinx.yml
AndreiDrang Apr 28, 2023
763dc2c
Update README.md
AndreiDrang Apr 28, 2023
0df6e6b
refactor
AndreiDrang Apr 28, 2023
cc567bc
Update lint.yml
AndreiDrang Apr 28, 2023
bc91990
upd docs
AndreiDrang Apr 28, 2023
ccb8e15
upd docs
AndreiDrang Apr 28, 2023
03f94c2
Update conf.py
AndreiDrang Apr 28, 2023
0871f96
0.6.1
AndreiDrang Apr 28, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/.coveragerc → .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ omit =
*/tests/*

include =
*/python3_captchaai/*
*/python3_capsolver/*


[report]
Expand All @@ -13,4 +13,4 @@ omit =
*/tests/*

include =
*/python3_captchaai/*
*/python3_capsolver/*
3 changes: 3 additions & 0 deletions .gitconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[user]
name = Andrei Drang
email = python-captcha@pm.me
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
name: Test Build
name: Build

on:
push:
branches: [ "main", "release"]
paths:
- '.github/workflows/test_build.yml'
- '.github/workflows/build.yml'
- 'src/**'
- 'Makefile'
pull_request:
branches: [ "main", "release"]
paths:
- '.github/workflows/test_build.yml'
- '.github/workflows/build.yml'
- 'src/**'
- 'Makefile'

Expand All @@ -20,7 +20,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10"]
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"]

steps:
- uses: actions/checkout@v3
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10"]
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"]

steps:
- uses: actions/checkout@v3
Expand All @@ -33,4 +33,4 @@ jobs:
run: make install

- name: PYPI install checking
run: pip install python3-captchaai
run: pip install python3-capsolver
4 changes: 2 additions & 2 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ["3.7", "3.8", "3.9", "3.10"]
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"]

steps:
- uses: actions/checkout@v3
Expand All @@ -37,6 +37,6 @@ jobs:
run: |
pip install --upgrade pip
pip install -r requirements.style.txt

- name: Lint
run: make lint
5 changes: 1 addition & 4 deletions .github/workflows/sphinx.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Sphinx build
name: Sphinx docs

on:
push:
Expand All @@ -20,9 +20,6 @@ jobs:
- name: Build docs requirements
run: pip install -r docs/requirements.txt

- name: Build library requirements
run: pip install -r src/requirements.txt

- name: Build docs
run: make doc

Expand Down
12 changes: 1 addition & 11 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,24 +1,14 @@
# Created by .ignore support plugin (hsz.mobi)
python_rucaptcha.egg-info/
\.idea/
Web-Interface/
/files/ico.png
src/python_rucaptcha/__pycache__/
build/

\.vscode/

src/examples/callback_examples/__pycache__/

CaptchaTester/callback_examples/__pycache__/

__pycache__/

dist/

env/
/.coverage
/src/python3_captchaai.egg-info/
/src/python3_capsolver.egg-info/
/src/.coverage
/src/coverage/lcov.info
/src/htmlcov/
Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2022 Andrei
Copyright (c) 2023 Andrei

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
24 changes: 12 additions & 12 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,38 +1,38 @@
install:
cd src/ && pip install -e .

remove:
pip uninstall python3_capsolver -y

refactor:
black docs/
isort docs/

cd src/ && \
autoflake --in-place \
--recursive \
--remove-unused-variables \
--remove-duplicate-keys \
--remove-all-unused-imports \
--ignore-init-module-imports \
python3_captchaai/ tests/ && \
black python3_captchaai/ tests/ && \
isort python3_captchaai/ tests/
src/ tests/ && \
black src/ tests/ && \
isort src/ tests/

lint:
cd src/ && \
autoflake --in-place --recursive python3_captchaai/ --check && \
black python3_captchaai/ --check && \
isort python3_captchaai/ --check-only
autoflake --in-place --recursive src/ --check && \
black src/ --check && \
isort src/ --check-only

upload:
pip install twine
cd src/ && python setup.py upload

tests:
cd src/ && \
coverage run --rcfile=.coveragerc -m pytest -s tests --disable-warnings && \
tests: install
coverage run --rcfile=.coveragerc -m pytest --verbose --showlocals --pastebin=all tests --disable-warnings && \
coverage report --precision=3 --sort=cover --skip-empty --show-missing && \
coverage html --precision=3 --skip-empty -d coverage/html/ && \
coverage xml -o coverage/coverage.xml

doc:
doc: install
cd docs/ && \
make html -e
42 changes: 25 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,28 @@
# python3-captchaai
![](files/CaptchaAISm.png)
# python3-capsolver
![Python3-Capsolver](https://github.com/AndreiDrang/python3-capsolver/blob/main/files/CapsolverSm.png)

[![PyPI version](https://badge.fury.io/py/python3-captchaai.svg)](https://badge.fury.io/py/python3-captchaai)
[![Python versions](https://img.shields.io/pypi/pyversions/python3-captchaai.svg?logo=python&logoColor=FBE072)](https://badge.fury.io/py/python3-captchaai)
[![Downloads](https://pepy.tech/badge/python3-captchaai/month)](https://pepy.tech/project/python3-captchaai)
[![Capsolver](https://user-images.githubusercontent.com/16991365/234852229-6e4b3f3c-f498-4fd5-9a6b-f7f269dd4bfc.gif)](https://dashboard.capsolver.com/passport/register?inviteCode=kQTn-tG07Jb1)

[![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)
[![PyPI version](https://badge.fury.io/py/python3-capsolver.svg)](https://badge.fury.io/py/python3-capsolver)
[![Python versions](https://img.shields.io/pypi/pyversions/python3-capsolver.svg?logo=python&logoColor=FBE072)](https://badge.fury.io/py/python3-capsolver)
[![Downloads](https://pepy.tech/badge/python3-capsolver/month)](https://pepy.tech/project/python3-capsolver)

[![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)
[![Installation check](https://github.com/AndreiDrang/python3-captchaai/actions/workflows/install.yml/badge.svg?branch=main)](https://github.com/AndreiDrang/python3-captchaai/actions/workflows/install.yml)
[![Test](https://github.com/AndreiDrang/python3-captchaai/actions/workflows/test.yml/badge.svg?branch=main)](https://github.com/AndreiDrang/python3-captchaai/actions/workflows/test.yml)
[![Lint](https://github.com/AndreiDrang/python3-captchaai/actions/workflows/lint.yml/badge.svg?branch=main)](https://github.com/AndreiDrang/python3-captchaai/actions/workflows/lint.yml)
[![Maintainability](https://api.codeclimate.com/v1/badges/3c30167b5fb37a0775ea/maintainability)](https://codeclimate.com/github/AndreiDrang/python3-capsolver/maintainability)
[![Codacy Badge](https://app.codacy.com/project/badge/Grade/323d4eda0fe1477bbea8fe8902b9e97e)](https://www.codacy.com/gh/AndreiDrang/python3-capsolver/dashboard?utm_source=github.com&utm_medium=referral&utm_content=AndreiDrang/python3-capsolver&utm_campaign=Badge_Grade)
[![codecov](https://codecov.io/gh/AndreiDrang/python3-capsolver/branch/main/graph/badge.svg?token=2L4VVIF4G8)](https://codecov.io/gh/AndreiDrang/python3-capsolver)

[![Sphinx build](https://github.com/AndreiDrang/python3-capsolver/actions/workflows/sphinx.yml/badge.svg?branch=release)](https://github.com/AndreiDrang/python3-capsolver/actions/workflows/sphinx.yml)
[![Build](https://github.com/AndreiDrang/python3-capsolver/actions/workflows/build.yml/badge.svg?branch=main)](https://github.com/AndreiDrang/python3-capsolver/actions/workflows/build.yml)
[![Installation](https://github.com/AndreiDrang/python3-capsolver/actions/workflows/install.yml/badge.svg?branch=main)](https://github.com/AndreiDrang/python3-capsolver/actions/workflows/install.yml)
[![Tests](https://github.com/AndreiDrang/python3-capsolver/actions/workflows/test.yml/badge.svg?branch=main)](https://github.com/AndreiDrang/python3-capsolver/actions/workflows/test.yml)
[![Lint](https://github.com/AndreiDrang/python3-capsolver/actions/workflows/lint.yml/badge.svg?branch=main)](https://github.com/AndreiDrang/python3-capsolver/actions/workflows/lint.yml)

Python 3 library for [Capsolver](https://capsolver.com/) service API.

Python 3 library for [Capsolver](https://dashboard.capsolver.com/passport/register?inviteCode=kQTn-tG07Jb1) service API.

Tested on UNIX based OS.

The library is intended for software developers and is used to work with the [Capsolver](https://capsolver.com/) service API.
The library is intended for software developers and is used to work with the [Capsolver](https://dashboard.capsolver.com/passport/register?inviteCode=kQTn-tG07Jb1) service API.

***

Expand All @@ -31,24 +34,29 @@ Or email python-captcha@pm.me

## How to install?

We recommend using the latest version of Python. `python3-captchaai` supports Python 3.7+.
We recommend using the latest version of Python. `python3-capsolver` supports Python 3.7+.

### pip

```bash
pip install python3-captchaai
pip install python3-capsolver
```

## How to use?

Is described in the [documentation-website](https://andreidrang.github.io/python3-captchaai/).
Is described in the [documentation-website](https://andreidrang.github.io/python3-capsolver/).


## How to test?

1. You need set ``API_KEY`` in your environment(get this value from you account).
2. Run command ``make tests``, from root directory.


### Changelog

Check [releases page](https://github.com/AndreiDrang/python3-capsolver/releases).

### How to get API Key to work with the library
1. On the page - https://dashboard.capsolver.com/overview/user-center
2. Find it: ![img.png](files/img.png)
File renamed without changes
File renamed without changes
File renamed without changes
41 changes: 20 additions & 21 deletions docs/conf.py
Original file line number Diff line number Diff line change
@@ -1,25 +1,24 @@
# -- Path setup --------------------------------------------------------------

import os
import sys
from datetime import date

from pallets_sphinx_themes import ProjectLink

os.chdir("../")
sys.path.insert(0, os.path.abspath("src/"))

for x in os.walk("src/python3_captchaai/"):
sys.path.insert(0, x[0])

from python3_captchaai import (core, datadome_slider, fun_captcha, gee_test,
hcaptcha, image_to_text, kasada, mt_captcha,
recaptcha)
from python3_captchaai.__version__ import __version__
from python3_capsolver import (
core,
gee_test,
hcaptcha,
recaptcha,
mt_captcha,
fun_captcha,
image_to_text,
datadome_slider,
)
from python3_capsolver.__version__ import __version__

# -- Project information -----------------------------------------------------

project = "python3-captchaai"
copyright = f"2023, AndreiDrang, Release - {__version__}"
project = "python3-capsolver"
copyright = f"{date.today().year}, AndreiDrang; Release - {__version__}; Last update - {date.today()}"
author = "AndreiDrang"

# -- General configuration ---------------------------------------------------
Expand All @@ -39,15 +38,15 @@
html_theme = "jinja"
html_theme_options = {"index_sidebar_logo": False}
html_static_path = ["_static"]
html_favicon = "_static/CaptchaAIESm.png"
html_logo = "_static/CaptchaAISm.png"
html_title = f"python3-captchaai ({__version__})"
html_favicon = "_static/CapsolverESm.png"
html_logo = "_static/CapsolverSM.png"
html_title = f"python3-capsolver ({__version__})"
html_show_sourcelink = False

html_context = {
"project_links": [
ProjectLink("PyPI Releases", "https://pypi.org/project/python3-captchaai/"),
ProjectLink("Source Code", "https://github.com/AndreiDrang/python3-captchaai"),
ProjectLink("PyPI Releases", "https://pypi.org/project/python3-capsolver/"),
ProjectLink("Source Code", "https://github.com/AndreiDrang/python3-capsolver"),
ProjectLink(
"Capsolver",
"https://dashboard.capsolver.com/passport/register?inviteCode=kQTn-tG07Jb1",
Expand All @@ -67,7 +66,7 @@
# Napoleon settings
napoleon_google_docstring = True
napoleon_numpy_docstring = False
napoleon_include_init_with_doc = False
napoleon_include_init_with_doc = True
napoleon_include_private_with_doc = False
napoleon_include_special_with_doc = False
napoleon_use_admonition_for_examples = True
Expand Down
5 changes: 2 additions & 3 deletions docs/index.rst
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
.. rst-class:: hide-header

python3-captchaai
python3-capsolver
=================
.. image:: _static/CaptchaAI300x.png
.. image:: _static/Capsolver300x.png
:align: center

Python3 library for `Capsolver API <https://dashboard.capsolver.com/passport/register?inviteCode=kQTn-tG07Jb1>`_.
Expand All @@ -29,7 +29,6 @@ The library is intended for software developers and is used to work with the `Ca
modules/fun-captcha/example.rst
modules/datadome/example.rst
modules/mt-captcha/example.rst
modules/kasada/example.rst

.. toctree::
:maxdepth: 2
Expand Down
12 changes: 12 additions & 0 deletions docs/modules/cloudflare/example.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
Cloudflare
==========

To import this module:

.. code-block:: python

from python3_capsolver.cloudflare import Cloudflare


.. autoclass:: python3_capsolver.cloudflare.Cloudflare
:members:
4 changes: 2 additions & 2 deletions docs/modules/datadome/example.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ To import this module:

.. code-block:: python

from python3_captchaai.datadome_slider import DatadomeSlider
from python3_capsolver.datadome_slider import DatadomeSlider


.. autoclass:: datadome_slider.DatadomeSlider
.. autoclass:: python3_capsolver.datadome_slider.DatadomeSlider
:members:
Loading