diff --git a/CHANGELOG.md b/CHANGELOG.md index 78c318f..ba0be71 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ ## [Unreleased] +- 🐛 — Fix bug in login view when having a cookie (internal server error) + ## 0.2.0 Date: 2024-06-24 diff --git a/argos/server/routes/views.py b/argos/server/routes/views.py index 0ca9f87..b889e42 100644 --- a/argos/server/routes/views.py +++ b/argos/server/routes/views.py @@ -30,7 +30,7 @@ SEVERITY_LEVELS = {"ok": 1, "warning": 2, "critical": 3, "unknown": 4} async def login_view(request: Request, msg: str | None = None): token = request.cookies.get("access-token") if token is not None: - manager = get_manager(request) + manager = request.app.state.manager user = await manager.get_current_user(token) if user is not None: return RedirectResponse( diff --git a/docs/developer/release.md b/docs/developer/release.md index db780cc..0947558 100644 --- a/docs/developer/release.md +++ b/docs/developer/release.md @@ -24,13 +24,13 @@ git checkout main make test # Bump the version, according to semantic versionning -hatch version minor # or `hatch version major` +hatch version minor # or `hatch version major`, or `hatch version fix` # Modify the changelog editor CHANGELOG.md # Commit the change -git add argos/__init__.py CHANGELOG +git add argos/__init__.py CHANGELOG.md git commit -m "🏷 — Bump version ($(hatch version))" # Create a tag on the git repository and push it @@ -45,7 +45,7 @@ hatch publish Aditionnaly, ensure it works well in a new environment. -Then go to https://framagit.org/framasoft/framaspace/argos/-/releases to create a new release for the new tag. +Then go to to create a new release for the new tag. Use CHANGELOG.md content for that. ## Bumping the version number