Skip to content

Commit

Permalink
Upgrade architecture + 5.0 Bot API (#469)
Browse files Browse the repository at this point in the history
Upgrade architecture + 5.0 Bot API (#469)
* Moved `methods`, `types` and `client` to root package
* Removed update handler from routers to dispatcher
* Reworked events propagation mechanism to handlers
* Reworked inner middlewares logic (very small change)
* Updated to Bot API 5.0
* Initial migration from MkDocs to Sphinx + config for readthedocs
  • Loading branch information
JrooTJunior committed Jan 26, 2021
1 parent 566b7ff commit 4008a31
Show file tree
Hide file tree
Showing 608 changed files with 12,527 additions and 6,417 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:

- name: Install dependencies
run: |
python -m pip install --upgrade pip poetry==1.0
python -m pip install --upgrade pip poetry==1.1.4
poetry install
mkdir -p reports
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
max-parallel: 6
fail-fast: false
matrix:
os:
- ubuntu-latest
Expand All @@ -21,6 +22,7 @@ jobs:
python-version:
- 3.7
- 3.8
- 3.9

steps:
- uses: actions/checkout@master
Expand All @@ -32,7 +34,7 @@ jobs:

- name: Install dependencies
run: |
python -m pip install --upgrade pip poetry==1.0
python -m pip install --upgrade pip poetry==1.1.4
poetry install
- name: Lint code
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
.idea/
.vscode/

__pycache__/
*.py[cod]

env/
build/
_build/
dist/
site/
*.egg-info/
Expand Down
14 changes: 14 additions & 0 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
version: 2

sphinx:
configuration: docs2/conf.py

formats: all

python:
version: 3.8
install:
- method: pip
path: .
extra_requirements:
- docs
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ clean:

.PHONY: isort
isort:
$(py) isort -rc aiogram tests
$(py) isort aiogram tests

.PHONY: black
black:
Expand Down
9 changes: 4 additions & 5 deletions aiogram/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
from .api import methods, types
from .api.client import session
from .api.client.bot import Bot
from .client import session
from .client.bot import Bot
from .dispatcher import filters, handler
from .dispatcher.dispatcher import Dispatcher
from .dispatcher.middlewares.base import BaseMiddleware
Expand Down Expand Up @@ -28,5 +27,5 @@
"handler",
)

__version__ = "3.0.0a5"
__api_version__ = "4.9"
__version__ = "3.0.0a6"
__api_version__ = "5.0"
Empty file.
38 changes: 0 additions & 38 deletions aiogram/api/client/telegram.py

This file was deleted.

44 changes: 0 additions & 44 deletions aiogram/api/methods/answer_callback_query.py

This file was deleted.

37 changes: 0 additions & 37 deletions aiogram/api/methods/answer_pre_checkout_query.py

This file was deleted.

40 changes: 0 additions & 40 deletions aiogram/api/methods/edit_message_caption.py

This file was deleted.

41 changes: 0 additions & 41 deletions aiogram/api/methods/edit_message_live_location.py

This file was deleted.

41 changes: 0 additions & 41 deletions aiogram/api/methods/edit_message_text.py

This file was deleted.

34 changes: 0 additions & 34 deletions aiogram/api/methods/export_chat_invite_link.py

This file was deleted.

0 comments on commit 4008a31

Please sign in to comment.