Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Unable to run custom queries against GitHub Actions

オープン
#2,755 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
25/100
issue の種類
バグ
明瞭さ
説明が足りない
活発さ
停滞
技術スタック
github-actions
領域
ci-cd, security

調査の方向性

まず、スタンドアロンの CodeQL コマンドと GitHub Actions の呼び出し、および生成された codescanning 設定を比較します。actions-queries/pull_request_target.ql と、リンク先の pull request に示されている workflow を調べ、Actions クエリが定義されていない理由を特定した後に workflow を再実行します。カスタムクエリが fatal error なしで Actions 経由で実行されれば完了です。

索引モデルが issue の本文から書いたものです。

説明

awaiting-response

I've been trying to use codeql to check my GitHub Actions workflows. I've got it kinda working here:

https://github.com/billnapier/github-actions-check-workflow/pulls

I can test things, and when I run codeql standalone, stuff works just fine:

codeql database create --force-overwrite --db-cluster /workspaces/c 
--source-root=/workspaces/github-actions-check-workflow --calculate-language-specific-baseline --extractor-include-aliases --sublanguage-file-
coverage --language=actions --search-path /workspaces/codeql-action --build-mode=none

and then run the query:

codeql query run --database /workspaces/c/actions -- actions-queries/pull_request_target.ql

So my query is well formed, and I can generate the DB. But when I try and run it via Actions, I get this output instead (also in the PR):

Encountered a fatal error while running "/opt/hostedtoolcache/CodeQL/2.20.3/x64/codeql/codeql database init --force-overwrite --db-cluster /home/runner/work/_temp/codeql_databases --source-root=/home/runner/work/github-actions-check-workflow/github-actions-check-workflow --calculate-language-specific-baseline --extractor-include-aliases --sublanguage-file-coverage --language=actions --search-path /home/runner/work/_actions/github/codeql-action/v3/actions-extractor --codescanning-config=/home/runner/work/_temp/user-config.yaml --build-mode=none". Exit code was 2 and error was: A fatal error occurred: No queries defined for actions. See the logs for more details.

I've been trying to debug the "No queries defined for actions", but I'm stumped. I'm guessing that I'm missing something specifying what language my query is used for, but I have no idea what I'm missing.

主要言語
TypeScript
スター
1.6k
フォーク
493
平均マージ
1日 13時間
マージ済み PR(30日)
44

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

github/codeql-action のほかの issue

github/codeql-action の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。