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: Discord斜杠指令同步有問題 #1246

Open
blufish1234 opened this issue Oct 30, 2023 · 3 comments
Open

Bug: Discord斜杠指令同步有問題 #1246

blufish1234 opened this issue Oct 30, 2023 · 3 comments
Labels
bug BUG

Comments

@blufish1234
Copy link

blufish1234 commented Oct 30, 2023

Describe the bug

Discord的斜杠指令同步似乎出現問題,比如指令不會即使被新增,刪除或修改。

Steps to reproduce

  1. 確保在discord適配器和指令設置裡開啟斜杠指令
  2. 修改,開啟或關閉指令設置中的斜杠指令
  3. 在discord客戶端查看修改結果
  4. 發現斜杠指令還是維持原樣

Expected behavior

斜杠指令應該與koishi及時同步

Screenshots

image
image

Versions

  • OS: Ubuntu 22.04 64位 UEFI版
  • Platform: Discord
  • Node version: 16.19.1
  • Koishi version: 4.15.3

Additional context

No response

@blufish1234 blufish1234 added the bug BUG label Oct 30, 2023
@CyanChanges
Copy link

似乎是预期的,关闭斜杠指令将不会进行同步
https://github.com/satorijs/satori/blob/master/adapters/discord/src/bot.ts#L194
Screenshot_20231030-201641

@Fox-ace
Copy link

Fox-ace commented Sep 21, 2024

我也出现同样的问题,也打开了斜杠指令

@DGCK81LNN
Copy link
Contributor

DGCK81LNN commented Oct 11, 2024

当存在无效的指令定义时,更新 Discord 斜杠指令的请求会返回一个报错。报错会显示请求体中有问题的指令的位置(json 路径),但不会显示有误的指令定义具体内容。

如果能找到上述报错,请确保指令与选项名不包含汉字或特殊字符,选项与参数无重名,并将 discord 日志等级设为 3 来显示请求体,以便解决问题。

相关:#1433

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

No branches or pull requests

4 participants