Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add new pipeline DTOs #58

Merged
merged 4 commits into from
Feb 19, 2024
Merged

Add new pipeline DTOs #58

merged 4 commits into from
Feb 19, 2024

Conversation

MichaelOwenDyer
Copy link
Contributor

Added some initial DTOs to use as deserialization targets in the endpoint subsystem as well as inputs in the pipeline subsystem.

Copy link
Member

@Hialus Hialus left a comment

Choose a reason for hiding this comment

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

2 general suggestions:

  1. Define the attributes on the class level (like you'd in Java). This makes it clearer what attributes each model has.
  2. Since these will be used as DTOs in FastAPI it would be beneficial if they use Pydantic for parsing them to/from JSON. For this they simply have to implement BaseModel and either have no init method or call super with all attributes the class has.

app/domain/dtos.py Show resolved Hide resolved
@Hialus Hialus merged commit db3c066 into main Feb 19, 2024
4 checks passed
@Hialus Hialus deleted the feature/pipeline-dtos branch February 19, 2024 17:24
@Hialus Hialus added this to the 1.0.0-Prototype milestone Feb 21, 2024
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.

None yet

3 participants