From 8e7c8a7e55501dd4d69a415279a260d334b6c8fe Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 18 Aug 2026 15:09:17 +0000 Subject: [PATCH 1/3] Initial plan From ee734f50eaa4b5fc862dfcdc178b397a7f6b99b1 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 18 Aug 2026 15:16:10 +0000 Subject: [PATCH 2/3] Remove stale copilot-otel.jsonl doc references Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com> --- .changeset/patch-remove-copilot-otel-jsonl-docs.md | 5 +++++ .github/skills/otel-queries/SKILL.md | 5 ++--- .github/workflows/smoke-otel-backends.lock.yml | 2 +- .github/workflows/smoke-otel-backends.md | 1 - docs/src/content/docs/guides/open-telemetry.mdx | 8 +++----- docs/src/content/docs/reference/artifacts.md | 1 - docs/src/content/docs/reference/open-telemetry.mdx | 1 - scratchpad/layout.md | 2 -- specs/otel-observability-spec.md | 4 +++- 9 files changed, 14 insertions(+), 15 deletions(-) create mode 100644 .changeset/patch-remove-copilot-otel-jsonl-docs.md diff --git a/.changeset/patch-remove-copilot-otel-jsonl-docs.md b/.changeset/patch-remove-copilot-otel-jsonl-docs.md new file mode 100644 index 00000000000..c6408bb5e9e --- /dev/null +++ b/.changeset/patch-remove-copilot-otel-jsonl-docs.md @@ -0,0 +1,5 @@ +--- +"gh-aw": patch +--- + +Remove stale documentation references to the `copilot-otel.jsonl` artifact, which was removed from the compiler and runtime in PR #32280. Docs, specs, and skills now describe Copilot CLI spans being exported directly to the configured OTLP backend instead of a local file mirror. diff --git a/.github/skills/otel-queries/SKILL.md b/.github/skills/otel-queries/SKILL.md index 8b5ceccb928..c29e2a5f9b5 100644 --- a/.github/skills/otel-queries/SKILL.md +++ b/.github/skills/otel-queries/SKILL.md @@ -36,9 +36,8 @@ Prefer sources in this order unless the user says otherwise: 1. Local artifacts or mirrors already in the workspace. 2. `/tmp/gh-aw/otel.jsonl` for gh-aw spans. -3. `/tmp/gh-aw/copilot-otel.jsonl` for Copilot CLI spans. -4. Live OTLP backend data through an MCP server or supported tool. -5. Static code inspection only, when no telemetry is available. +3. Live OTLP backend data through an MCP server or supported tool — Copilot CLI spans are exported directly to the configured OTLP backend (no local file mirror) and must be queried there, filtered by the `github.run_id` resource attribute. +4. Static code inspection only, when no telemetry is available. Use the cheapest source that can disconfirm the current hypothesis. diff --git a/.github/workflows/smoke-otel-backends.lock.yml b/.github/workflows/smoke-otel-backends.lock.yml index bb005c2c79a..befcc06276d 100644 --- a/.github/workflows/smoke-otel-backends.lock.yml +++ b/.github/workflows/smoke-otel-backends.lock.yml @@ -1,4 +1,4 @@ -# gh-aw-metadata: {"schema_version":"v4","frontmatter_hash":"3b298dad1f8fe5c3be791c9e74c4f2617926c9b450475302549a3bb8ea83fe36","body_hash":"7e62e3a591bebb7534c9e64bcaa093c1fb0711032de7cdfd3519a7429a26ade6","strict":true,"agent_id":"copilot","engine_versions":{"copilot":"1.0.80"}} +# gh-aw-metadata: {"schema_version":"v4","frontmatter_hash":"3b298dad1f8fe5c3be791c9e74c4f2617926c9b450475302549a3bb8ea83fe36","body_hash":"17aff5317be9e08d74021a469b9f857c520cf280dadc9d2d02fd90f6bac8e3c6","strict":true,"agent_id":"copilot","engine_versions":{"copilot":"1.0.80"}} # gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","DD_API_KEY","DD_APPLICATION_KEY","DD_APP_KEY","DD_SITE","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GH_AW_OTEL_DATADOG_API_KEY","GH_AW_OTEL_DATADOG_ENDPOINT","GH_AW_OTEL_GRAFANA_AUTHORIZATION","GH_AW_OTEL_GRAFANA_ENDPOINT","GH_AW_OTEL_SENTRY_AUTHORIZATION","GH_AW_OTEL_SENTRY_ENDPOINT","GITHUB_TOKEN","GRAFANA_SERVICE_ACCOUNT_TOKEN","GRAFANA_URL","SENTRY_ACCESS_TOKEN","SENTRY_OPENAI_API_KEY"],"actions":[{"repo":"actions/cache/restore","sha":"55cc8345863c7cc4c66a329aec7e433d2d1c52a9","version":"v6.1.0"},{"repo":"actions/cache/save","sha":"55cc8345863c7cc4c66a329aec7e433d2d1c52a9","version":"v6.1.0"},{"repo":"actions/checkout","sha":"3d3c42e5aac5ba805825da76410c181273ba90b1","version":"v7.0.1"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9.0.0"},{"repo":"actions/setup-node","sha":"820762786026740c76f36085b0efc47a31fe5020","version":"v7.0.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.28.1","digest":"sha256:5e3f6ee27eeae07195838b97ac4aa2f8aea42a7c55f1c0d3e17d8e88e294ad0d","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.28.1@sha256:5e3f6ee27eeae07195838b97ac4aa2f8aea42a7c55f1c0d3e17d8e88e294ad0d"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.28.1","digest":"sha256:288e7d2a12d5b430500d739f9c16e20bb1ed51b91f986f3f3eccde189f489f5c","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.28.1@sha256:288e7d2a12d5b430500d739f9c16e20bb1ed51b91f986f3f3eccde189f489f5c"},{"image":"ghcr.io/github/gh-aw-firewall/cli-proxy:0.28.1","digest":"sha256:f931e5e1e13f765605d03ef9511fc755d779a51b76581ea14586e9871506a610","pinned_image":"ghcr.io/github/gh-aw-firewall/cli-proxy:0.28.1@sha256:f931e5e1e13f765605d03ef9511fc755d779a51b76581ea14586e9871506a610"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.28.1","digest":"sha256:9d428af47899bf18ef2d5618075777d76ef344c91e76c1f44ec1aaa0ee347e5f","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.28.1@sha256:9d428af47899bf18ef2d5618075777d76ef344c91e76c1f44ec1aaa0ee347e5f"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.4.9","digest":"sha256:e5a1569aeaf41820fa7bdee3e94468cae448133cdbf00119ad24f5b74db1ab9f","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.4.9@sha256:e5a1569aeaf41820fa7bdee3e94468cae448133cdbf00119ad24f5b74db1ab9f"},{"image":"ghcr.io/github/gh-aw-node","digest":"sha256:0d9f1fb5fd6610c0ac1f5194a38e45a8a1e81f8a390d5142d8e4e6f26a4b3196","pinned_image":"ghcr.io/github/gh-aw-node@sha256:0d9f1fb5fd6610c0ac1f5194a38e45a8a1e81f8a390d5142d8e4e6f26a4b3196"},{"image":"ghcr.io/github/github-mcp-server:v1.9.0","digest":"sha256:881b53d6f75f69bdbc1b5b10fc2f1361717c19054143b3a8529fb5c32061a50e","pinned_image":"ghcr.io/github/github-mcp-server:v1.9.0@sha256:881b53d6f75f69bdbc1b5b10fc2f1361717c19054143b3a8529fb5c32061a50e"},{"image":"grafana/mcp-grafana:1.1.0-alpine","digest":"sha256:e0eb29cdf8effbbebf115ea99a5f654a44681dfd293661b0991498d651ca6cb4","pinned_image":"grafana/mcp-grafana:1.1.0-alpine@sha256:e0eb29cdf8effbbebf115ea99a5f654a44681dfd293661b0991498d651ca6cb4"},{"image":"node:lts-alpine","digest":"sha256:d32cdf619f63fe0471182d08996dd516c6275bb5fd31ae06e55a570bd9e1ad43","pinned_image":"node:lts-alpine@sha256:d32cdf619f63fe0471182d08996dd516c6275bb5fd31ae06e55a570bd9e1ad43"}]} # This file was automatically generated by gh-aw. DO NOT EDIT. To debug this workflow, load the skill at https://github.com/github/gh-aw/blob/main/debug.md # diff --git a/.github/workflows/smoke-otel-backends.md b/.github/workflows/smoke-otel-backends.md index 5456e77a876..e35129b350a 100644 --- a/.github/workflows/smoke-otel-backends.md +++ b/.github/workflows/smoke-otel-backends.md @@ -114,7 +114,6 @@ echo "OTEL_EXPORTER_OTLP_ENDPOINT=${OTEL_EXPORTER_OTLP_ENDPOINT:+set}" echo "OTEL_EXPORTER_OTLP_HEADERS=${OTEL_EXPORTER_OTLP_HEADERS:+set}" echo "GH_AW_OTLP_ENDPOINTS=${GH_AW_OTLP_ENDPOINTS:+set}" echo "OTEL_SERVICE_NAME=${OTEL_SERVICE_NAME:-}" -echo "COPILOT_OTEL_FILE_EXPORTER_PATH=${COPILOT_OTEL_FILE_EXPORTER_PATH:-}" echo "=== OTEL configured backend hosts ===" if [ -n "${GH_AW_OTLP_ENDPOINTS:-}" ]; then diff --git a/docs/src/content/docs/guides/open-telemetry.mdx b/docs/src/content/docs/guides/open-telemetry.mdx index f0cb091150e..fd79587d40d 100644 --- a/docs/src/content/docs/guides/open-telemetry.mdx +++ b/docs/src/content/docs/guides/open-telemetry.mdx @@ -124,7 +124,8 @@ You usually do not need to configure or memorize these built-in attributes. They When observability is enabled, trace data is also mirrored to local JSONL files and uploaded in the `agent` artifact: - `otel.jsonl` for spans emitted by gh-aw JavaScript helpers -- `copilot-otel.jsonl` for spans emitted by Copilot CLI + +Copilot CLI inherits the standard OpenTelemetry environment variables (`OTEL_EXPORTER_OTLP_ENDPOINT`, `OTEL_EXPORTER_OTLP_HEADERS`, `OTEL_SERVICE_NAME`, `OTEL_RESOURCE_ATTRIBUTES`) and exports its own spans directly to the configured OTLP backend. Query them there, filtered by the `github.run_id` resource attribute (see [ADR-34450](https://github.com/github/gh-aw/blob/main/docs/adr/32280-pass-otel-headers-as-container-env-var.md)). See [Artifacts](/gh-aw/reference/artifacts/) for artifact download details. @@ -228,7 +229,7 @@ await otlp.logSpan('my-scanner', { Attribute values are sanitized automatically before the payload is exported or mirrored. Matching secret-like keys are redacted, and very long string values are truncated. The same sanitization is applied to both OTLP export and the local JSONL mirror. -For debugging, every span emitted by `logSpan` is appended as a sanitized JSON line to `/tmp/gh-aw/otel.jsonl`, even when `OTEL_EXPORTER_OTLP_ENDPOINT` is not set. When OTLP is configured, Copilot CLI spans are written to `/tmp/gh-aw/copilot-otel.jsonl` and forwarded to configured endpoints at the end of the run. Both files are included in the `agent` artifact when OTLP is enabled. +For debugging, every span emitted by `logSpan` is appended as a sanitized JSON line to `/tmp/gh-aw/otel.jsonl`, even when `OTEL_EXPORTER_OTLP_ENDPOINT` is not set. This file is included in the `agent` artifact when OTLP is enabled. Copilot CLI spans are not mirrored to a local file; they are exported directly to the configured OTLP backend and should be queried there. ```bash # Download agent artifacts for a run @@ -236,9 +237,6 @@ gh aw logs --artifacts agent # Inspect spans emitted by your tool cat otel.jsonl | jq 'select(.resourceSpans[].scopeSpans[].spans[].name | startswith("my-tool"))' - -# Inspect Copilot CLI spans -cat copilot-otel.jsonl | jq '.resourceSpans' ```
diff --git a/docs/src/content/docs/reference/artifacts.md b/docs/src/content/docs/reference/artifacts.md index 96c53f89ef7..44870b165a5 100644 --- a/docs/src/content/docs/reference/artifacts.md +++ b/docs/src/content/docs/reference/artifacts.md @@ -148,7 +148,6 @@ The unified `agent` artifact contains agent job outputs: - GitHub API rate limit logs (`github_rate_limits.jsonl`) - Token usage summary (`agent_usage.json`) — aggregated totals only; per-request data is in `firewall-audit-logs` - `otel.jsonl` — OTLP span mirror written by gh-aw's JavaScript span exporters when `observability.otlp` is configured -- `copilot-otel.jsonl` — OTLP spans emitted by Copilot CLI when `observability.otlp` is configured For OTLP configuration, runtime environment variables, and span semantics, see the [OpenTelemetry guide](/gh-aw/guides/open-telemetry/). diff --git a/docs/src/content/docs/reference/open-telemetry.mdx b/docs/src/content/docs/reference/open-telemetry.mdx index 6e9c994a804..da41f30833c 100644 --- a/docs/src/content/docs/reference/open-telemetry.mdx +++ b/docs/src/content/docs/reference/open-telemetry.mdx @@ -259,7 +259,6 @@ These attributes are emitted when experiments are active for a run. When observability is enabled, trace data is also mirrored to local JSONL files and uploaded in the agent artifact: - otel.jsonl for spans emitted by gh-aw JavaScript helpers -- copilot-otel.jsonl for spans emitted by Copilot CLI See the [OpenTelemetry guide](/gh-aw/guides/open-telemetry/) for setup and [Artifacts](/gh-aw/reference/artifacts/) for artifact download details. diff --git a/scratchpad/layout.md b/scratchpad/layout.md index 6f8cd8c6cd0..6298683c177 100644 --- a/scratchpad/layout.md +++ b/scratchpad/layout.md @@ -194,7 +194,6 @@ Common file paths referenced in workflow files: | `/tmp/gh-aw/aw_info.json` | File | Workflow info JSON | Workflow metadata and configuration | | `/tmp/gh-aw/awf-config.json` | File | AWF config JSON | Agentic Workflow Firewall (AWF) configuration file | | `/tmp/gh-aw/base` | Directory | Base checkout | Base repository checkout for git diff operations | -| `/tmp/gh-aw/copilot-otel.jsonl` | File | Copilot OTEL log | OpenTelemetry spans from Copilot engine requests | | `/tmp/gh-aw/cache-memory` | Directory | Cache memory storage | Persistent cache data across runs | | `/tmp/gh-aw/cache-memory-chroma` | Directory | Chroma cache storage | Chroma vector database cache | | `/tmp/gh-aw/cache-memory-focus-areas` | Directory | Focus areas cache | Cached focus area data | @@ -649,7 +648,6 @@ GitHub Actions runner images used across compiled workflows: ├── cache-memory-repo-audits/ # Audit cache ├── comment-memory/ # Comment memory │ └── default.md -├── copilot-otel.jsonl # Copilot OpenTelemetry spans ├── experiments/ # A/B experiments │ ├── assignments.json │ └── state.json diff --git a/specs/otel-observability-spec.md b/specs/otel-observability-spec.md index 9b29cf40fd9..7e2c6932334 100644 --- a/specs/otel-observability-spec.md +++ b/specs/otel-observability-spec.md @@ -753,7 +753,7 @@ Mirror-write failure MUST produce a structured diagnostic but SHOULD NOT fail th The mirror writer MUST create parent directories with restrictive permissions, MUST use append-safe writes, SHOULD tolerate concurrent writers, MUST NOT write exporter credentials, MUST apply the same content-capture and redaction policy as remote export, and SHOULD rotate or bound file size. -When telemetry artifacts are uploaded, the artifact SHOULD contain `otel.jsonl`, runtime-specific companion files such as `copilot-otel.jsonl` when present, and no secret headers or credentials. A manifest containing schema version, signal counts, byte sizes, and redaction mode MAY be added as an optional companion file. +When telemetry artifacts are uploaded, the artifact SHOULD contain `otel.jsonl` and no secret headers or credentials. As of the removal in PR #32280, gh-aw does not produce a runtime-specific companion mirror file for Copilot CLI spans; Copilot CLI is expected to export its spans directly to the configured OTLP backend using the injected `OTEL_EXPORTER_OTLP_ENDPOINT`/`OTEL_EXPORTER_OTLP_HEADERS`/`OTEL_RESOURCE_ATTRIBUTES` environment variables (see ADR-34450). A manifest containing schema version, signal counts, byte sizes, and redaction mode MAY be added as an optional companion file. --- @@ -953,6 +953,8 @@ context is added to outcome spans or links. ### Version 0.4.0 (Working Draft, June 18, 2026) +- **Removed** (documentation correction, August 2026): References to a `copilot-otel.jsonl` local mirror/companion artifact. PR #32280 removed the file-export pipeline that produced it (`COPILOT_OTEL_FILE_EXPORTER_PATH` injection, artifact inclusion, and forwarding script); Copilot CLI spans are now expected to be exported directly to the configured OTLP backend and queried there. + - **Changed**: Reframed 0.4.0 as a non-breaking compatibility revision rather than a replacement telemetry standard. - **Preserved**: `observability.otlp`, direct OTLP export, `OTEL_EXPORTER_OTLP_ENDPOINT`, `OTEL_EXPORTER_OTLP_HEADERS`, `GITHUB_AW_OTEL_TRACE_ID`, `GITHUB_AW_OTEL_PARENT_SPAN_ID`, `TRACEPARENT` compatibility, built-in setup/conclusion spans, `gen_ai.system`, `gen_ai.usage.total_tokens`, and raw OTLP JSONL mirror behavior. - **Clarified**: Standard OpenTelemetry attributes such as `gen_ai.provider.name` and CI/CD attributes may be emitted as additive aliases, not replacements for existing fields. From ef550c1ed6c3f9a1264cb56d263956eccbfa1b26 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 18 Aug 2026 15:17:01 +0000 Subject: [PATCH 3/3] Fix ADR link to correct file (34450) Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com> --- docs/src/content/docs/guides/open-telemetry.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/src/content/docs/guides/open-telemetry.mdx b/docs/src/content/docs/guides/open-telemetry.mdx index fd79587d40d..a2a84172453 100644 --- a/docs/src/content/docs/guides/open-telemetry.mdx +++ b/docs/src/content/docs/guides/open-telemetry.mdx @@ -125,7 +125,7 @@ When observability is enabled, trace data is also mirrored to local JSONL files - `otel.jsonl` for spans emitted by gh-aw JavaScript helpers -Copilot CLI inherits the standard OpenTelemetry environment variables (`OTEL_EXPORTER_OTLP_ENDPOINT`, `OTEL_EXPORTER_OTLP_HEADERS`, `OTEL_SERVICE_NAME`, `OTEL_RESOURCE_ATTRIBUTES`) and exports its own spans directly to the configured OTLP backend. Query them there, filtered by the `github.run_id` resource attribute (see [ADR-34450](https://github.com/github/gh-aw/blob/main/docs/adr/32280-pass-otel-headers-as-container-env-var.md)). +Copilot CLI inherits the standard OpenTelemetry environment variables (`OTEL_EXPORTER_OTLP_ENDPOINT`, `OTEL_EXPORTER_OTLP_HEADERS`, `OTEL_SERVICE_NAME`, `OTEL_RESOURCE_ATTRIBUTES`) and exports its own spans directly to the configured OTLP backend. Query them there, filtered by the `github.run_id` resource attribute (see [ADR-34450](https://github.com/github/gh-aw/blob/main/docs/adr/34450-inject-otel-resource-attributes-for-child-otel-sdk-correlation.md)). See [Artifacts](/gh-aw/reference/artifacts/) for artifact download details.