Skip to content

Commit

Permalink
Bump the pip-minor-patch group with 16 updates (#81)
Browse files Browse the repository at this point in the history
* Bump the pip-minor-patch group with 16 updates

Bumps the pip-minor-patch group with 16 updates:

| Package | From | To |
| --- | --- | --- |
| [uvicorn](https://github.com/encode/uvicorn) | `0.18.3` | `0.25.0` |
| [aiohttp](https://github.com/aio-libs/aiohttp) | `3.8.3` | `3.9.1` |
| [aiomysql](https://github.com/aio-libs/aiomysql) | `0.1.1` | `0.2.0` |
| [asyncpg](https://github.com/MagicStack/asyncpg) | `0.26.0` | `0.29.0` |
| [sentry-sdk](https://github.com/getsentry/sentry-python) | `1.9.10` | `1.39.1` |
| [httpx](https://github.com/encode/httpx) | `0.23.0` | `0.26.0` |
| [alembic](https://github.com/sqlalchemy/alembic) | `1.8.1` | `1.13.1` |
| [pyjwt](https://github.com/jpadilla/pyjwt) | `2.5.0` | `2.8.0` |
| [icalendar](https://github.com/collective/icalendar) | `5.0.0` | `5.0.11` |
| [isort](https://github.com/pycqa/isort) | `5.12.0` | `5.13.2` |
| [wemake-python-styleguide](https://github.com/wemake-services/wemake-python-styleguide) | `0.16.1` | `0.17.0` |
| [pytest](https://github.com/pytest-dev/pytest) | `7.1.3` | `7.4.3` |
| [pytest-asyncio](https://github.com/pytest-dev/pytest-asyncio) | `0.19.0` | `0.23.2` |
| [pytest-mock](https://github.com/pytest-dev/pytest-mock) | `3.8.2` | `3.12.0` |
| [aiosqlite](https://github.com/omnilib/aiosqlite) | `0.17.0` | `0.19.0` |
| [ruff](https://github.com/astral-sh/ruff) | `0.1.5` | `0.1.9` |


Updates `uvicorn` from 0.18.3 to 0.25.0
- [Release notes](https://github.com/encode/uvicorn/releases)
- [Changelog](https://github.com/encode/uvicorn/blob/master/CHANGELOG.md)
- [Commits](encode/uvicorn@0.18.3...0.25.0)

Updates `aiohttp` from 3.8.3 to 3.9.1
- [Release notes](https://github.com/aio-libs/aiohttp/releases)
- [Changelog](https://github.com/aio-libs/aiohttp/blob/master/CHANGES.rst)
- [Commits](aio-libs/aiohttp@v3.8.3...v3.9.1)

Updates `aiomysql` from 0.1.1 to 0.2.0
- [Release notes](https://github.com/aio-libs/aiomysql/releases)
- [Changelog](https://github.com/aio-libs/aiomysql/blob/master/CHANGES.txt)
- [Commits](aio-libs/aiomysql@v0.1.1...v0.2.0)

Updates `asyncpg` from 0.26.0 to 0.29.0
- [Release notes](https://github.com/MagicStack/asyncpg/releases)
- [Commits](MagicStack/asyncpg@v0.26.0...v0.29.0)

Updates `sentry-sdk` from 1.9.10 to 1.39.1
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGELOG.md)
- [Commits](getsentry/sentry-python@1.9.10...1.39.1)

Updates `httpx` from 0.23.0 to 0.26.0
- [Release notes](https://github.com/encode/httpx/releases)
- [Changelog](https://github.com/encode/httpx/blob/master/CHANGELOG.md)
- [Commits](encode/httpx@0.23.0...0.26.0)

Updates `alembic` from 1.8.1 to 1.13.1
- [Release notes](https://github.com/sqlalchemy/alembic/releases)
- [Changelog](https://github.com/sqlalchemy/alembic/blob/main/CHANGES)
- [Commits](https://github.com/sqlalchemy/alembic/commits)

Updates `pyjwt` from 2.5.0 to 2.8.0
- [Release notes](https://github.com/jpadilla/pyjwt/releases)
- [Changelog](https://github.com/jpadilla/pyjwt/blob/master/CHANGELOG.rst)
- [Commits](jpadilla/pyjwt@2.5.0...2.8.0)

Updates `icalendar` from 5.0.0 to 5.0.11
- [Changelog](https://github.com/collective/icalendar/blob/master/CHANGES.rst)
- [Commits](collective/icalendar@v5.0.0...v5.0.11)

Updates `isort` from 5.12.0 to 5.13.2
- [Release notes](https://github.com/pycqa/isort/releases)
- [Changelog](https://github.com/PyCQA/isort/blob/main/CHANGELOG.md)
- [Commits](PyCQA/isort@5.12.0...5.13.2)

Updates `wemake-python-styleguide` from 0.16.1 to 0.17.0
- [Release notes](https://github.com/wemake-services/wemake-python-styleguide/releases)
- [Changelog](https://github.com/wemake-services/wemake-python-styleguide/blob/master/CHANGELOG.md)
- [Commits](wemake-services/wemake-python-styleguide@0.16.1...0.17.0)

Updates `pytest` from 7.1.3 to 7.4.3
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst)
- [Commits](pytest-dev/pytest@7.1.3...7.4.3)

Updates `pytest-asyncio` from 0.19.0 to 0.23.2
- [Release notes](https://github.com/pytest-dev/pytest-asyncio/releases)
- [Commits](pytest-dev/pytest-asyncio@v0.19.0...v0.23.2)

Updates `pytest-mock` from 3.8.2 to 3.12.0
- [Release notes](https://github.com/pytest-dev/pytest-mock/releases)
- [Changelog](https://github.com/pytest-dev/pytest-mock/blob/main/CHANGELOG.rst)
- [Commits](pytest-dev/pytest-mock@v3.8.2...v3.12.0)

Updates `aiosqlite` from 0.17.0 to 0.19.0
- [Changelog](https://github.com/omnilib/aiosqlite/blob/main/CHANGELOG.md)
- [Commits](omnilib/aiosqlite@v0.17.0...v0.19.0)

Updates `ruff` from 0.1.5 to 0.1.9
- [Release notes](https://github.com/astral-sh/ruff/releases)
- [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md)
- [Commits](astral-sh/ruff@v0.1.5...v0.1.9)

---
updated-dependencies:
- dependency-name: uvicorn
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: aiohttp
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: aiomysql
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: asyncpg
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: sentry-sdk
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: httpx
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: alembic
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: pyjwt
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: icalendar
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: pip-minor-patch
- dependency-name: isort
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: wemake-python-styleguide
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: pytest
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: pytest-asyncio
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: pytest-mock
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: aiosqlite
  dependency-type: direct:development
  update-type: version-update:semver-minor
  dependency-group: pip-minor-patch
- dependency-name: ruff
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: pip-minor-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Fix mypy error

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Defelo <elodef42@gmail.com>
  • Loading branch information
dependabot[bot] and Defelo authored Dec 22, 2023
1 parent 47d29a2 commit 68c0b51
Show file tree
Hide file tree
Showing 3 changed files with 281 additions and 320 deletions.
17 changes: 10 additions & 7 deletions api/utils/jwt.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from datetime import timedelta
from typing import Any
from typing import Any, cast

import jwt

Expand All @@ -15,12 +15,15 @@ def decode_jwt(
token: str, *, require: list[str] | None = None, audience: list[str] | None = None
) -> dict[Any, Any] | None:
try:
return jwt.decode(
token,
settings.jwt_secret,
["HS256"],
audience=audience,
options={"require": [*{*(require or []), "exp"}], "verify_aud": bool(audience)},
return cast(
dict[Any, Any],
jwt.decode(
token,
settings.jwt_secret,
["HS256"],
audience=audience,
options={"require": [*{*(require or []), "exp"}], "verify_aud": bool(audience)},
),
)
except jwt.InvalidTokenError:
return None
Loading

0 comments on commit 68c0b51

Please sign in to comment.