自我检查
- 这仅用于提交错误报告,如果您想提问,请访问 Discussions 。
- 我已在现有问题中搜索 search for existing issues (包括已关闭的问题)。
- 我确认我使用英文提交此报告(我已阅读并同意 Language Policy )。
- 请务必使用英文提交问题,否则会被关闭。谢谢!:)
- 请不要修改此模板 :) 并填写所有必填字段。
Dify版本
0.6.14
云或自托管
自托管(Docker)
重现步骤
当我设置 Notion - 添加工作区时,它报告“内部服务器错误”。
我按照此文档中的说明操作 - https://docs.dify.ai/guides/knowledge-base/sync-from-notion 并编辑了 .env 文件。
NOTION_INTEGRATION_TYPE=internal
NOTION_INTERNAL_SECRET=secret_dFRK56YmrJZCmMda7J5VfqWDoKDmwlr9FWBCHpIgABC
但它仍然报告相同的问题。
以及以下的 docker log,
✔️ 预期行为
修复该问题。
❌ 实际行为
- 无响应*
3条答案
按热度按时间vm0i2vca1#
顺便说一下,由于保密原因,我在这里修改了内部秘密代码。
cedebl8k2#
要解决在Dify版本0.6.14的自托管Docker环境中与Notion集成遇到的"Internal Server Error",请按照以下步骤操作:
确保您的
.env
文件中正确设置了以下环境变量:NotionOAuth
类:错误信息表明与
TypeError
相关的vars()
函数问题。可以通过确保NotionOAuth
类具有__dict__
属性来解决此问题。请按照以下方式修改类:如果在类中定义了
__slots__
,请将其删除:在进行这些更改后,重启您的Docker容器以应用更新。
这些步骤应该有助于解决您在使用Notion集成时遇到的内部服务器错误。
uklbhaso3#
第39行:oauth_provider = OAUTH_DATASOURCE_PROVIDERS.get(provider)
返回Nonetype,因为Vars()无法正常工作。