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

Use typing.Annotated for schema types #158

Closed
perdy opened this issue Nov 22, 2024 · 0 comments · Fixed by #159
Closed

Use typing.Annotated for schema types #158

perdy opened this issue Nov 22, 2024 · 0 comments · Fixed by #159
Assignees
Labels
feature request Request for a new feature
Milestone

Comments

@perdy
Copy link
Member

perdy commented Nov 22, 2024

Summary

Use typing.Annotated for schema types

Motivation

Currently types.Schema is based on dicts type and it produces type checking errors on return values for functions.

This could be resolved by using typing.Annotation.

Proposed changes

Replace the current types.Schema implementation by an annotated dict that includes the schema as part of the annotation.

@perdy perdy added the feature request Request for a new feature label Nov 22, 2024
@perdy perdy changed the title Use typing.Annotated as backend for types.Schema Use typing.Annotated for schema types Nov 23, 2024
This was linked to pull requests Nov 23, 2024
@perdy perdy removed a link to a pull request Nov 23, 2024
@perdy perdy self-assigned this Nov 24, 2024
@perdy perdy added this to the 1.9.0 milestone Nov 24, 2024
github-actions bot pushed a commit that referenced this issue Nov 24, 2024
# [v1.9.0](v1.8.1...v1.9.0) (2024-11-24)

## ✨ New Features
- [`de06aec`](de06aec)  Use typing.Annotated for schema types (#158) (Issues: [`#158`](https://github.com/vortico/flama/issues/))
- [`259a873`](259a873)  Allow importing ddd without sqlalchemy installed (#161) (Issues: [`#161`](https://github.com/vortico/flama/issues/))
- [`0b62909`](0b62909)  Compatibility lib for older python versions (#160) (Issues: [`#160`](https://github.com/vortico/flama/issues/))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Request for a new feature
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant