diff --git a/.github/workflows/daily-syntax-error-quality.lock.yml b/.github/workflows/daily-syntax-error-quality.lock.yml index f0f334f14dd..ee59fcb9bd5 100644 --- a/.github/workflows/daily-syntax-error-quality.lock.yml +++ b/.github/workflows/daily-syntax-error-quality.lock.yml @@ -1,4 +1,4 @@ -# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"0c93874c181cdd6df0a5cc4b6fbd95ce143efbc10cdc39240ce0b3d29ea81c8c","strict":true,"agent_id":"copilot"} +# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"3b4232eff1a0cd5bd7ae4e4aa48acf238bc123aa91947ac6f16a5cb9e4ab0d83","strict":true,"agent_id":"copilot"} # ___ _ _ # / _ \ | | (_) # | |_| | __ _ ___ _ __ | |_ _ ___ @@ -155,14 +155,14 @@ jobs: run: | bash ${RUNNER_TEMP}/gh-aw/actions/create_prompt_first.sh { - cat << 'GH_AW_PROMPT_b38712c0f975a468_EOF' + cat << 'GH_AW_PROMPT_d927af6819e96e9f_EOF' - GH_AW_PROMPT_b38712c0f975a468_EOF + GH_AW_PROMPT_d927af6819e96e9f_EOF cat "${RUNNER_TEMP}/gh-aw/prompts/xpia.md" cat "${RUNNER_TEMP}/gh-aw/prompts/temp_folder_prompt.md" cat "${RUNNER_TEMP}/gh-aw/prompts/markdown.md" cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_prompt.md" - cat << 'GH_AW_PROMPT_b38712c0f975a468_EOF' + cat << 'GH_AW_PROMPT_d927af6819e96e9f_EOF' Tools: create_issue, missing_tool, missing_data, noop @@ -194,14 +194,14 @@ jobs: {{/if}} - GH_AW_PROMPT_b38712c0f975a468_EOF + GH_AW_PROMPT_d927af6819e96e9f_EOF cat "${RUNNER_TEMP}/gh-aw/prompts/github_mcp_tools_with_safeoutputs_prompt.md" - cat << 'GH_AW_PROMPT_b38712c0f975a468_EOF' + cat << 'GH_AW_PROMPT_d927af6819e96e9f_EOF' {{#runtime-import .github/workflows/shared/reporting.md}} {{#runtime-import .github/workflows/shared/observability-otlp.md}} {{#runtime-import .github/workflows/daily-syntax-error-quality.md}} - GH_AW_PROMPT_b38712c0f975a468_EOF + GH_AW_PROMPT_d927af6819e96e9f_EOF } > "$GH_AW_PROMPT" - name: Interpolate variables and render templates uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8 @@ -390,9 +390,9 @@ jobs: mkdir -p ${RUNNER_TEMP}/gh-aw/safeoutputs mkdir -p /tmp/gh-aw/safeoutputs mkdir -p /tmp/gh-aw/mcp-logs/safeoutputs - cat > ${RUNNER_TEMP}/gh-aw/safeoutputs/config.json << 'GH_AW_SAFE_OUTPUTS_CONFIG_2262b3ec70380289_EOF' + cat > ${RUNNER_TEMP}/gh-aw/safeoutputs/config.json << 'GH_AW_SAFE_OUTPUTS_CONFIG_f4c96f7ec5bc898f_EOF' {"create_issue":{"close_older_issues":true,"expires":72,"labels":["dx","error-messages","automated-analysis"],"max":1,"title_prefix":"[syntax-error-quality] "},"create_report_incomplete_issue":{},"missing_data":{},"missing_tool":{},"noop":{"max":1,"report-as-issue":"true"},"report_incomplete":{}} - GH_AW_SAFE_OUTPUTS_CONFIG_2262b3ec70380289_EOF + GH_AW_SAFE_OUTPUTS_CONFIG_f4c96f7ec5bc898f_EOF - name: Write Safe Outputs Tools env: GH_AW_TOOLS_META_JSON: | @@ -592,7 +592,7 @@ jobs: if [ -n "${OTEL_EXPORTER_OTLP_HEADERS:-}" ]; then _GH_AW_OTLP_HEADERS_JSON=$(node -e 'const h=process.env["OTEL_EXPORTER_OTLP_HEADERS"]||"";const o={};h.split(",").forEach(function(p){const i=p.indexOf("=");if(i>0)o[p.slice(0,i).trim()]=p.slice(i+1).trim();});console.log(JSON.stringify(o));' 2>/dev/null || echo "{}") fi - cat << GH_AW_MCP_CONFIG_61f60ed6eb4fe33f_EOF | bash ${RUNNER_TEMP}/gh-aw/actions/start_mcp_gateway.sh + cat << GH_AW_MCP_CONFIG_c6373df6ff35befd_EOF | bash ${RUNNER_TEMP}/gh-aw/actions/start_mcp_gateway.sh { "mcpServers": { "github": { @@ -639,7 +639,7 @@ jobs: } } } - GH_AW_MCP_CONFIG_61f60ed6eb4fe33f_EOF + GH_AW_MCP_CONFIG_c6373df6ff35befd_EOF - name: Download activation artifact uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1 with: @@ -654,17 +654,19 @@ jobs: # --allow-tool github # --allow-tool safeoutputs # --allow-tool shell(cat .github/workflows/*.md) - # --allow-tool shell(cat /tmp/*.md) + # --allow-tool shell(cat /tmp/gh-aw/syntax-error-tests/*.md) # --allow-tool shell(cat) - # --allow-tool shell(cp .github/workflows/*.md /tmp/*.md) + # --allow-tool shell(cp .github/workflows/*.md /tmp/gh-aw/syntax-error-tests/*.md) # --allow-tool shell(date) # --allow-tool shell(echo) # --allow-tool shell(find .github/workflows -name '*.md' -type f ! -name 'daily-*.md' ! -name '*-test.md') # --allow-tool shell(gh aw compile *) + # --allow-tool shell(gh aw compile /tmp/gh-aw/syntax-error-tests/*.md) # --allow-tool shell(grep) # --allow-tool shell(head -n * .github/workflows/*.md) # --allow-tool shell(head) # --allow-tool shell(ls) + # --allow-tool shell(mkdir -p /tmp/gh-aw/syntax-error-tests) # --allow-tool shell(pwd) # --allow-tool shell(sort) # --allow-tool shell(tail) @@ -678,7 +680,7 @@ jobs: touch /tmp/gh-aw/agent-step-summary.md # shellcheck disable=SC1003 sudo -E awf --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --exclude-env GITHUB_MCP_SERVER_TOKEN --exclude-env MCP_GATEWAY_API_KEY --allow-domains api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,github.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,www.googleapis.com --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --image-tag 0.25.13 --skip-pull --enable-api-proxy \ - -- /bin/bash -c '/usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --allow-tool github --allow-tool safeoutputs --allow-tool '\''shell(cat .github/workflows/*.md)'\'' --allow-tool '\''shell(cat /tmp/*.md)'\'' --allow-tool '\''shell(cat)'\'' --allow-tool '\''shell(cp .github/workflows/*.md /tmp/*.md)'\'' --allow-tool '\''shell(date)'\'' --allow-tool '\''shell(echo)'\'' --allow-tool '\''shell(find .github/workflows -name '\''\'\'''\''*.md'\''\'\'''\'' -type f ! -name '\''\'\'''\''daily-*.md'\''\'\'''\'' ! -name '\''\'\'''\''*-test.md'\''\'\'''\'')'\'' --allow-tool '\''shell(gh aw compile *)'\'' --allow-tool '\''shell(grep)'\'' --allow-tool '\''shell(head -n * .github/workflows/*.md)'\'' --allow-tool '\''shell(head)'\'' --allow-tool '\''shell(ls)'\'' --allow-tool '\''shell(pwd)'\'' --allow-tool '\''shell(sort)'\'' --allow-tool '\''shell(tail)'\'' --allow-tool '\''shell(uniq)'\'' --allow-tool '\''shell(wc)'\'' --allow-tool '\''shell(yq)'\'' --allow-tool write --allow-all-paths --add-dir "${GITHUB_WORKSPACE}" --prompt "$(cat /tmp/gh-aw/aw-prompts/prompt.txt)"' 2>&1 | tee -a /tmp/gh-aw/agent-stdio.log + -- /bin/bash -c '/usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --allow-tool github --allow-tool safeoutputs --allow-tool '\''shell(cat .github/workflows/*.md)'\'' --allow-tool '\''shell(cat /tmp/gh-aw/syntax-error-tests/*.md)'\'' --allow-tool '\''shell(cat)'\'' --allow-tool '\''shell(cp .github/workflows/*.md /tmp/gh-aw/syntax-error-tests/*.md)'\'' --allow-tool '\''shell(date)'\'' --allow-tool '\''shell(echo)'\'' --allow-tool '\''shell(find .github/workflows -name '\''\'\'''\''*.md'\''\'\'''\'' -type f ! -name '\''\'\'''\''daily-*.md'\''\'\'''\'' ! -name '\''\'\'''\''*-test.md'\''\'\'''\'')'\'' --allow-tool '\''shell(gh aw compile *)'\'' --allow-tool '\''shell(gh aw compile /tmp/gh-aw/syntax-error-tests/*.md)'\'' --allow-tool '\''shell(grep)'\'' --allow-tool '\''shell(head -n * .github/workflows/*.md)'\'' --allow-tool '\''shell(head)'\'' --allow-tool '\''shell(ls)'\'' --allow-tool '\''shell(mkdir -p /tmp/gh-aw/syntax-error-tests)'\'' --allow-tool '\''shell(pwd)'\'' --allow-tool '\''shell(sort)'\'' --allow-tool '\''shell(tail)'\'' --allow-tool '\''shell(uniq)'\'' --allow-tool '\''shell(wc)'\'' --allow-tool '\''shell(yq)'\'' --allow-tool write --allow-all-paths --add-dir "${GITHUB_WORKSPACE}" --prompt "$(cat /tmp/gh-aw/aw-prompts/prompt.txt)"' 2>&1 | tee -a /tmp/gh-aw/agent-stdio.log env: COPILOT_AGENT_RUNNER_TYPE: STANDALONE COPILOT_GITHUB_TOKEN: ${{ github.token }} diff --git a/.github/workflows/daily-syntax-error-quality.md b/.github/workflows/daily-syntax-error-quality.md index 4531c6cc97e..690dd387516 100644 --- a/.github/workflows/daily-syntax-error-quality.md +++ b/.github/workflows/daily-syntax-error-quality.md @@ -11,16 +11,15 @@ permissions: tracker-id: daily-syntax-error-quality engine: copilot tools: - github: - toolsets: - - default bash: - "find .github/workflows -name '*.md' -type f ! -name 'daily-*.md' ! -name '*-test.md'" - "gh aw compile *" + - "gh aw compile /tmp/gh-aw/syntax-error-tests/*.md" - "cat .github/workflows/*.md" - "head -n * .github/workflows/*.md" - - "cp .github/workflows/*.md /tmp/*.md" - - "cat /tmp/*.md" + - "cp .github/workflows/*.md /tmp/gh-aw/syntax-error-tests/*.md" + - "cat /tmp/gh-aw/syntax-error-tests/*.md" + - "mkdir -p /tmp/gh-aw/syntax-error-tests" safe-outputs: create-issue: expires: 3d @@ -162,8 +161,8 @@ For each workflow: 1. **Copy workflow to /tmp** for testing: ```bash - mkdir -p /tmp/syntax-error-tests - cp .github/workflows/selected-workflow.md /tmp/syntax-error-tests/test-1.md + mkdir -p /tmp/gh-aw/syntax-error-tests + cp .github/workflows/selected-workflow.md /tmp/gh-aw/syntax-error-tests/test-1.md ``` 2. **Introduce ONE error** from a different category: @@ -187,7 +186,7 @@ For each test case: 1. **Attempt to compile** the modified workflow: ```bash - cd /tmp/syntax-error-tests + cd /tmp/gh-aw/syntax-error-tests gh aw compile test-1.md 2>&1 | tee test-1-output.txt ```