Skip to content

ci: updated deps and python3.13#233

Merged
MarcusDragsten merged 1 commit intomainfrom
update-deps
Mar 4, 2026
Merged

ci: updated deps and python3.13#233
MarcusDragsten merged 1 commit intomainfrom
update-deps

Conversation

@MarcusDragsten
Copy link
Copy Markdown
Contributor

What does this pull request change?

Why is this pull request needed?

Issues related to this change

@MarcusDragsten MarcusDragsten requested a review from a team as a code owner March 4, 2026 08:54
Copilot AI review requested due to automatic review settings March 4, 2026 08:54
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR upgrades the project’s runtime/tooling stack (Python/FastAPI/Pydantic) and updates the job API code to use Pydantic v2 serialization/validation APIs.

Changes:

  • Migrate Pydantic usage from v1 APIs (.dict()/.json()/.parse_obj) to v2 APIs (model_dump/model_dump_json/model_validate) across job services and REST responses.
  • Upgrade Python target and core dependencies in pyproject.toml and refresh poetry.lock accordingly.
  • Update build/CI configuration (Dockerfile, pre-commit, GitHub Actions) to use Python 3.14.

Reviewed changes

Copilot reviewed 14 out of 15 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/utils/exception_handlers.py Switches validation error response serialization to model_dump().
src/services/job_service.py Migrates job persistence/DMSS update payloads to model_dump_json() and adjusts progress return serialization.
src/services/job_handler_interface.py Updates Pydantic model config and validation/serialization helpers for v2 (ConfigDict, model_validate, model_dump).
src/restful/responses.py Updates error response examples/JSONResponse payloads to use model_dump() and updates ValidationError import.
src/features/jobs/use_cases/update_job_progress.py Updates Pydantic BaseModel import style (v2-friendly).
src/features/jobs/use_cases/status_job.py Migrates Pydantic config to ConfigDict for enum value dumping.
src/features/jobs/use_cases/start_job.py Updates Pydantic BaseModel import style (v2-friendly).
src/features/jobs/use_cases/delete_job.py Updates Pydantic BaseModel import style (v2-friendly).
src/features/jobs/jobs.py Replaces .dict() route return payloads with model_dump().
src/domain_classes/progress.py Updates Pydantic BaseModel import style (v2-friendly).
pyproject.toml Bumps Python + key dependencies and updates Black target version.
poetry.lock Lockfile refresh to match updated dependency set.
Dockerfile Moves base image to Python 3.14 and normalizes stage naming.
.pre-commit-config.yaml Updates pre-commit Python interpreter version to 3.14 (hook configs still need alignment).
.github/workflows/tests.yaml Updates CI to set up Python 3.14.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@MarcusDragsten MarcusDragsten changed the title lets pray 🙏 ci: updated deps and python3.13 Mar 4, 2026
@MarcusDragsten MarcusDragsten requested a review from Copilot March 4, 2026 11:15
@MarcusDragsten MarcusDragsten merged commit 23f2514 into main Mar 4, 2026
7 checks passed
@MarcusDragsten MarcusDragsten deleted the update-deps branch March 4, 2026 11:19
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 16 out of 17 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

type="RequestValidationError",
message="The received values are invalid",
debug="The received values are invalid according to the endpoints model definition",
extra=jsonable_encoder({"detail": exc.errors(), "body": exc.body}),
Copy link

Copilot AI Mar 4, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ErrorResponse (imported from restful.responses) doesn't define an extra field, so the extra=... payload will be silently dropped when building the response model. If you intend to return validation details to clients, pass this data via the existing data field (or add an explicit extra field/config that preserves unknown fields).

Suggested change
extra=jsonable_encoder({"detail": exc.errors(), "body": exc.body}),
data=jsonable_encoder({"detail": exc.errors(), "body": exc.body}),

Copilot uses AI. Check for mistakes.
[tool.black]
line-length = 119
target-version = ['py10']
target-version = ['py312']
Copy link

Copilot AI Mar 4, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pyproject.toml now requires Python ^3.13, but Black is configured with target-version = ['py312']. If the codebase is intended to allow Python 3.13 syntax/features, Black will treat them as invalid for the configured target and may fail/complain. Consider updating Black's target-version to match the project's minimum Python (or document why formatting/validation is intentionally capped at 3.12).

Suggested change
target-version = ['py312']
target-version = ['py313']

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants