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

solution to py-cache-decorator #1408

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

Annolel
Copy link

@Annolel Annolel commented Nov 18, 2024

Checks by pytest and flake8 were passed successfully.

Copy link

@Alkaponees Alkaponees left a comment

Choose a reason for hiding this comment

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

Check my review

app/main.py Outdated

tmp_cache = {}

def inner(*args) -> None:

Choose a reason for hiding this comment

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

Recommend importing from typing Any also. Use it for this function.

Copy link
Author

Choose a reason for hiding this comment

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

Why should I even import this "any" thing? I can just make it like:
def inner(*args):
Isn't it the same?

@Annolel
Copy link
Author

Annolel commented Nov 19, 2024

"Any" type was imported and added to the decorator function to describe it's output type correctly.

@Annolel Annolel requested a review from Alkaponees November 19, 2024 18:34
Copy link

@Alkaponees Alkaponees left a comment

Choose a reason for hiding this comment

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

LGMT!

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.

2 participants