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

尝试为aapi.py中的部分方法添加TypedDict类型注解 #354

Open
xiyihan0 opened this issue Apr 19, 2024 · 3 comments
Open

尝试为aapi.py中的部分方法添加TypedDict类型注解 #354

xiyihan0 opened this issue Apr 19, 2024 · 3 comments

Comments

@xiyihan0
Copy link
Contributor

为aapi.py中的部分方法(包括搜索功能,用户收藏,用户关注,小说评论)添加了类型注解,(不知道这么写合不合适)

my code

@upbit
Copy link
Owner

upbit commented Apr 21, 2024

可以帮忙提交个MR,我看看修改内容。

另外,注释方面如果能用GPT/文心一言等大模型,翻译个英文版放着对比更好

@xiyihan0
Copy link
Contributor Author

可以试试,但你的自动测试的Python版本得调整到至少3.8(你的pyproject.toml上也写的是3.8版本),因为从这个版本开始才会支持TypedDict。另外,我这里确实可以考虑添加一下文档注释,方便查看具体功能

@upbit
Copy link
Owner

upbit commented Apr 21, 2024

可以试试,但你的自动测试的Python版本得调整到至少3.8(你的pyproject.toml上也写的是3.8版本),因为从这个版本开始才会支持TypedDict。另外,我这里确实可以考虑添加一下文档注释,方便查看具体功能

嗯,往上调整吧。目前大多应该都在3.9或者更新版本了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants