Skip to content

[bug] idd-report:Discussions 的 GraphQL 呼叫照抄會失敗(query 變數撞名、mutation 沒傳變數)(follow-up from #353 verify) #360

Description

@kiki830621

Problem

idd-report 的三段 Discussions GraphQL 呼叫照抄執行都會失敗。

  • Step 6(搜尋既有報告):GraphQL 文件用 -f query='…' 傳入,搜尋字串又用 -f query="repo:$GITHUB_REPO {report_title}" 傳一次。兩個欄位同名,後者覆蓋前者,GitHub 收到的 GraphQL 文件變成那串搜尋字串,解析失敗。變數應改名,例如 $q,並用 -f q=… 傳。
  • Step 8(CREATE / UPDATE):mutation 宣告了 $repoId / $catId / $title / $body(UPDATE 是 $id / $body),呼叫時一個變數都沒傳。

Expected

三段呼叫都能照抄執行;變數名不與 query 欄位相撞;每個宣告的變數都有對應的 -f。仿照 #353 的做法,加一個以 stub gh 實際執行這幾段 snippet 的 suite。

Context

#353 驗證第一輪時發現。與 #353 同類:skill 裡寫的 GraphQL 呼叫從沒真的跑過,錯了也沒人發現。


Follow-up from #353 verify

Source: /idd-verify #353 第 1、2 輪(PR #358)

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions