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 annotations to return values #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

SirTelemak
Copy link

I think it's nice to have annotation for return values :) I'd liked to use something instead of List[dict] but it feels kinda confusing to use List[Dict[str, Union[str, list]]. I'd use pydantic model here or dataclass, but it's overkill here imo

@kabirkhan
Copy link
Contributor

Sorry for the late review on this but thanks for taking an interest!

I'd prefer the more detailed type annotation rather than List[dict] but your point on just using Pydantic models is valid and I'd welcome that contribution if you'd like to make it.

Otherwise, I'll plan to update this repo with some best practice changes (like using Pydantic types all the way through) later this month or next month

@SirTelemak
Copy link
Author

Sure, I'll make PR using Pydantic models. Can't say when, but hope I'll have time this month

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

2 participants