Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
9dc0065
Add the reporting window and command line for telemetry error issues
anth-volk Oct 20, 2026
c62a086
Normalize services, environments and stack frames for error grouping
anth-volk Oct 20, 2026
752de77
Choose one record per failure and fingerprint its error group
anth-volk Oct 20, 2026
39a73a1
Measure each telemetry error group in production and staging
anth-volk Oct 20, 2026
b3acba5
Query telemetry error records and request counts from BigQuery
anth-volk Oct 20, 2026
60f4df5
Render telemetry error groups as GitHub issue titles and bodies
anth-volk Oct 20, 2026
5056cf1
Create and update one GitHub issue per production error group
anth-volk Oct 20, 2026
511a3ae
Run the telemetry error report end to end with public-safe output
anth-volk Oct 20, 2026
efbaa06
Add the daily telemetry error issues workflow and its wrapper
anth-volk Oct 20, 2026
1538f61
Record the telemetry error issues infrastructure created on 2026-10-20
anth-volk Oct 20, 2026
0a9f0c5
Fingerprint exceptions by the first traceback of a chained stack
anth-volk Oct 20, 2026
3820f0d
Keep apostrophes from turning message values into the template
anth-volk Oct 20, 2026
72fb855
Compute the error rate only from failures on routes
anth-volk Oct 20, 2026
a142e7a
Match existing GitHub labels regardless of case
anth-volk Oct 20, 2026
5944147
Follow GitHub's rate-limit guidance for 403 responses without retry-a…
anth-volk Oct 20, 2026
98d2309
Split the telemetry error issue script and its tests into modules
anth-volk Oct 27, 2026
f67d4b4
Read the telemetry log names and namespace from repository variables
anth-volk Oct 27, 2026
238ae7b
Query BigQuery with google-cloud-bigquery instead of our own REST client
anth-volk Oct 27, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .github/scripts/sync_telemetry_error_issues.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
"""Report each day's telemetry error groups as GitHub issues.

The code is in the ``telemetry_error_issues`` package beside this file. Python
puts the directory of a script it runs by path first on ``sys.path``, so the
package imports from any working directory.
"""

from telemetry_error_issues.cli import main

if __name__ == "__main__":
raise SystemExit(main())
35 changes: 35 additions & 0 deletions .github/scripts/sync_telemetry_error_issues.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
#!/usr/bin/env bash
# Run the daily telemetry error report with the settings the workflow passes
# in the environment, through uv (the workflow sets it up). DRY_RUN=true adds --dry-run; a non-empty REPORT_DATE
# (YYYY-MM-DD, an Eastern calendar day) replaces the default previous day.
set -euo pipefail

: "${GOOGLE_OAUTH_ACCESS_TOKEN:?GOOGLE_OAUTH_ACCESS_TOKEN is required}"
: "${GITHUB_TOKEN:?GITHUB_TOKEN is required}"
: "${GITHUB_REPOSITORY:?GITHUB_REPOSITORY is required}"
: "${TELEMETRY_ERROR_FINGERPRINT_KEY:?TELEMETRY_ERROR_FINGERPRINT_KEY is required}"
: "${OBSERVABILITY_PROJECT_ID:?OBSERVABILITY_PROJECT_ID is required}"
: "${OBSERVABILITY_LOG_BUCKET:?OBSERVABILITY_LOG_BUCKET is required}"
: "${OBSERVABILITY_LOG_BUCKET_LOCATION:?OBSERVABILITY_LOG_BUCKET_LOCATION is required}"
: "${OBSERVABILITY_LOG_DATASET:?OBSERVABILITY_LOG_DATASET is required}"
: "${OBSERVABILITY_LOG_VIEW:?OBSERVABILITY_LOG_VIEW is required}"
: "${OBSERVABILITY_SERVICE_NAMESPACE:?OBSERVABILITY_SERVICE_NAMESPACE is required}"

# Hide both values in the job log even if a later command prints them.
echo "::add-mask::${GOOGLE_OAUTH_ACCESS_TOKEN}"
echo "::add-mask::${TELEMETRY_ERROR_FINGERPRINT_KEY}"

arguments=(--project-id "${OBSERVABILITY_PROJECT_ID}")
if [[ "${DRY_RUN:-false}" == "true" ]]; then
arguments+=(--dry-run)
fi
if [[ -n "${REPORT_DATE:-}" ]]; then
arguments+=(--report-date "${REPORT_DATE}")
fi

script_directory="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
repository_root="$(cd "${script_directory}/../.." && pwd)"
# Run in an environment that holds only the telemetry-error-issues dependency
# group, at the versions uv.lock pins, not the API's own dependencies.
exec uv run --frozen --only-group telemetry-error-issues --project "${repository_root}" \
python "${script_directory}/sync_telemetry_error_issues.py" "${arguments[@]}"
13 changes: 13 additions & 0 deletions .github/scripts/telemetry_error_issues/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
"""Report each day's telemetry error groups as GitHub issues.

Each run reads one US Eastern calendar day of error records from the central
Cloud Logging bucket through its linked BigQuery dataset. It groups the records
by a keyed fingerprint, measures each group in production and staging, and
creates or updates one GitHub issue per production error group.

Workflow logs, job summaries and issues in this repository are public. The
script therefore publishes only fingerprints, counts, code-defined names and a
Logs Explorer link, never error messages, stack text or identifiers.

``sync_telemetry_error_issues.py`` beside this package runs ``cli.main``.
"""
Loading
Loading