-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #42 from reagento/develop
v0.5
- Loading branch information
Showing
32 changed files
with
741 additions
and
203 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# This workflow will install Python dependencies, run tests and lint with a single version of Python | ||
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python | ||
|
||
name: CI | ||
|
||
on: | ||
push: | ||
branches: [ "develop" ] | ||
pull_request: | ||
branches: [ "develop" ] | ||
|
||
jobs: | ||
cpython: | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: | ||
- ubuntu-latest | ||
python-version: | ||
- "3.10" | ||
- "3.11" | ||
- "3.12" | ||
- "3.13" | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up ${{ matrix.python-version }} on ${{ matrix.os }} | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install '.' -r requirements_dev.txt | ||
- name: Run ruff | ||
run: | | ||
ruff check . | ||
- name: Run tests | ||
run: | | ||
pytest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
line-length = 79 | ||
target-version="py38" | ||
src = ["src"] | ||
|
||
include = ["src/**.py", "tests/**.py"] | ||
exclude = ["src/dishka/_adaptix/**"] | ||
|
||
lint.select = [ | ||
"ALL" | ||
] | ||
lint.ignore = [ | ||
"ARG", | ||
"ANN", | ||
"D", | ||
"EM101", | ||
"EM102", | ||
"PT001", | ||
"PT023", | ||
"SIM108", | ||
"SIM114", | ||
"TRY003", | ||
"PLW2901", | ||
"RET505", | ||
"RET506", | ||
"PLR0913", | ||
"UP038", | ||
"TCH001", | ||
"FA100", | ||
# tempraty disabled | ||
"PGH005", | ||
"PLR2004", | ||
"N818", # compatibility issue | ||
] | ||
|
||
[lint.per-file-ignores] | ||
"tests/**" = ["TID252", "PLR2004", "S101", "A002"] | ||
|
||
[lint.isort] | ||
no-lines-before = ["local-folder"] | ||
|
||
[lint.flake8-tidy-imports] | ||
ban-relative-imports = "parents" |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
[build-system] | ||
requires = ["setuptools>=66.0"] | ||
build-backend = "setuptools.build_meta" | ||
|
||
[tool.setuptools] | ||
include-package-data = true | ||
|
||
[tool.setuptools.packages.find] | ||
where = ["src"] | ||
|
||
[project] | ||
name = "dataclass_rest" | ||
version = "0.4" | ||
readme = "README.md" | ||
authors = [ | ||
{ name = "Andrey Tikhonov", email = "[email protected]" }, | ||
] | ||
license = { text = "Apache-2.0" } | ||
description = "An utility for writing simple clients for REST like APIs" | ||
requires-python = ">=3.8" | ||
classifiers = [ | ||
"Programming Language :: Python :: 3", | ||
"Topic :: Software Development :: Libraries", | ||
"Typing :: Typed", | ||
"Intended Audience :: Developers", | ||
"License :: OSI Approved :: Apache Software License", | ||
"Operating System :: OS Independent", | ||
] | ||
dependencies = [ | ||
"adaptix", | ||
] | ||
|
||
[project.urls] | ||
"Source" = "https://github.com/reagento/dataclass-rest" | ||
"Homepage" = "https://github.com/reagento/dataclass-rest" | ||
"Bug Tracker" = "https://github.com/reagento/dataclass-rest/issues" | ||
|
||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
adaptix | ||
typing_extensions | ||
aiohttp | ||
requests | ||
requests-mock | ||
mypy | ||
pytest | ||
pytest-asyncio | ||
|
||
ruff==0.5.* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
__all__ = [ | ||
"File", | ||
"rest", | ||
"get", | ||
"put", | ||
"post", | ||
"patch", | ||
"delete", | ||
] | ||
|
||
from .http_request import File | ||
from .rest import delete, get, patch, post, put, rest |
3 changes: 2 additions & 1 deletion
3
dataclass_rest/base_client.py → src/dataclass_rest/base_client.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.