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

Bug: 配置项无法使用 ONEBOT_ACCESS_TOKEN #94

Closed
A-n-k-a opened this issue Feb 17, 2024 · 5 comments · Fixed by #96
Closed

Bug: 配置项无法使用 ONEBOT_ACCESS_TOKEN #94

A-n-k-a opened this issue Feb 17, 2024 · 5 comments · Fixed by #96
Labels
question Further information is requested

Comments

@A-n-k-a
Copy link

A-n-k-a commented Feb 17, 2024

文档原文为ONEBOT_ACCESS_TOKEN=你的访问令牌
通过阅读代码得知正确配置应为ONEBOT_V12_ACCESS_TOKEN=你的访问令牌

@yanyongyu
Copy link
Member

pydantic是两个名称都应该生效的

@yanyongyu yanyongyu added the question Further information is requested label Feb 17, 2024
@A-n-k-a
Copy link
Author

A-n-k-a commented Feb 17, 2024

我实际使用时发现如果填写ONEBOT_ACCESS_TOKEN=你的访问令牌,相当于未设置令牌,只有ONEBOT_V12_ACCESS_TOKEN=你的访问令牌才会传递认证令牌。

@yanyongyu
Copy link
Member

你使用的pydantic版本是?

@yanyongyu
Copy link
Member

看上去可能是缺了populate by name配置

@A-n-k-a
Copy link
Author

A-n-k-a commented Feb 17, 2024

我使用的pydantic版本是1.10

@yanyongyu yanyongyu changed the title 文档内“配置访问权限”一节中“access_token”配置有误 Bug: 配置项无法使用 ONEBOT_ACCESS_TOKEN Feb 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Development

Successfully merging a pull request may close this issue.

2 participants