Dep updates (#35)

* Dep updates

* black

* mypy
This commit is contained in:
Ethan Roseman 2023-12-18 18:49:51 +09:00 committed by GitHub
parent 74174af81e
commit defeb51bd9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 284 additions and 467 deletions

View File

@ -9,7 +9,7 @@ jobs:
name: tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: '3.10'
@ -22,7 +22,7 @@ jobs:
name: mypy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: '3.10'
@ -34,7 +34,7 @@ jobs:
name: black
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: '3.10'

View File

@ -1,6 +1,3 @@
{
"python.linting.mypyEnabled": true,
"python.linting.enabled": true,
"python.formatting.provider": "black",
"editor.formatOnSave": true
}

View File

@ -2,7 +2,7 @@ FROM python:3.11-slim
RUN apt-get update && apt-get install -y curl netcat
ARG POETRY_VERSION=1.2.2
ARG POETRY_VERSION=1.7.1
ENV POETRY_VERSION=${POETRY_VERSION}
RUN curl -sSL https://install.python-poetry.org | \
POETRY_VERSION=${POETRY_VERSION} POETRY_HOME=/etc/poetry python -

View File

@ -1,4 +1,4 @@
from typing import Optional
from typing import Any, Optional
from django.core.cache import cache
from rest_framework.utils.serializer_helpers import ReturnDict
@ -11,7 +11,7 @@ def _entries_cache_key(project_slug: str, version_slug: str, category_slug: str)
def get_entries_cache(
project_slug: str, version_slug: str, category_slug: str
) -> Optional[ReturnDict]:
) -> Optional[ReturnDict[str, Any]]:
"""
Fetches cached entries data.
"""
@ -19,7 +19,7 @@ def get_entries_cache(
def set_entries_cache(
project_slug: str, version_slug: str, category_slug: str, data: ReturnDict
project_slug: str, version_slug: str, category_slug: str, data: ReturnDict[str, Any]
) -> None:
"""
Updates cached entries data.
@ -32,7 +32,7 @@ def set_entries_cache(
def invalidate_entries_cache(
project_slug: str, version_slug: str, data: ReturnDict
project_slug: str, version_slug: str, data: ReturnDict[str, Any]
) -> None:
"""
Invalidates all affected entries caches.

View File

@ -5,7 +5,6 @@ import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
(
"frog_api",

View File

@ -4,7 +4,6 @@ from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
("frog_api", "0010_alter_entry_category_alter_project_discord_and_more"),
]

707
poetry.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -1,24 +1,25 @@
[tool.poetry]
name = "frogress"
version = "0.3.0"
version = "0.4.0"
description = "Progress API for decompilation projects"
authors = ["Ethan Roseman <ethteck@gmail.com>"]
license = "MIT"
[tool.poetry.dependencies]
python = "^3.8"
Django = "^4.1"
djangorestframework = "^3.13.1"
django-nested-admin = "^3.4.0"
python = "^3.10"
Django = "^5.0"
djangorestframework = "^3.14.0"
django-nested-admin = "^4.0.2"
django-environ = "^0.9.0"
setuptools = "^69.0.2"
[tool.poetry.group.dev.dependencies]
black = "^22.6.0"
mypy = "^0.971"
django-stubs = "^1.12.0"
djangorestframework-stubs = "^1.7.0"
django-stubs-ext = "^0.5.0"
gunicorn = "^20.1.0"
black = "^23.12.0"
mypy = "^1.7.1"
django-stubs = "^4.2.7"
djangorestframework-stubs = "^3.14.5"
django-stubs-ext = "^4.2.7"
gunicorn = "^21.2.0"
[build-system]
requires = ["poetry-core>=1.0.0"]