Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions .github/firebase-mcp.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"_comment": "DRAFT β€” Firebase MCP server config for the crashlytics-autotriage workflow. See docs/PRD-crashlytics-autotriage.md. Requires Application Default Credentials (provided by google-github-actions/auth) with roles/firebasecrashlytics.viewer.",
"_comment": "Firebase MCP server config for the crashlytics-autotriage workflow. `--only crashlytics` activates the (experimental) Crashlytics tool group β€” it is NOT in the default tool set, so without it the crashlytics_* tools never surface. Requires Application Default Credentials (from google-github-actions/auth) on a service account with roles/firebasecrashlytics.viewer. See docs/PRD-crashlytics-autotriage.md.",
"mcpServers": {
"firebase": {
"command": "npx",
"args": ["-y", "firebase-tools@latest", "mcp", "--dir", ".", "--project", "openloop-8c266"]
"args": ["-y", "firebase-tools@latest", "mcp", "--dir", ".", "--project", "openloop-8c266", "--only", "crashlytics"]
}
}
}
23 changes: 12 additions & 11 deletions .github/workflows/crashlytics-autotriage.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,21 @@
name: Crashlytics auto-triage

# ============================================================================
# DRAFT β€” NOT YET ENABLED. Pending owner sign-off of docs/PRD-crashlytics-autotriage.md.
# Do not enable until the secrets / service account in the PRD exist.
# ENABLED β€” Phase 0 (triage + draft PR). See docs/PRD-crashlytics-autotriage.md and
# docs/FIREBASE.md for the full design and runbook.
#
# Trigger: a Crashlytics-sourced GitHub issue (created by the Cloud Function in functions/)
# carrying the `crashlytics-auto` label is opened. Claude reads the crash via the Firebase
# MCP server, posts a root-cause comment, and β€” when confident β€” opens a DRAFT PR with a
# first-pass fix. Nothing is ever auto-merged. See the PRD for the full design.
# Trigger: when an issue is LABELED `crashlytics-auto`. The Cloud Function applies that
# label when it files a crash; a human can also add it to an existing issue. Claude reads
# the crash via the Firebase MCP server, posts a root-cause comment, and β€” when confident β€”
# opens a DRAFT PR with a first-pass fix. Nothing is ever auto-merged.
#
# We trigger ONLY on `labeled` (not `opened`) so an issue created-with-label fires exactly
# one triage run instead of two (which would double the Claude API spend per crash).
# ============================================================================

on:
issues:
types: [opened, labeled]
types: [labeled]
workflow_dispatch:
inputs:
issue_number:
Expand All @@ -31,12 +34,10 @@ concurrency:

jobs:
triage:
# Only run for Crashlytics-sourced issues (label gate) or an explicit manual dispatch,
# so human-filed issues never spend tokens.
# Only run when the `crashlytics-auto` label is applied, or on an explicit manual dispatch,
# so other labels and human-filed issues never spend tokens.
if: >
github.event_name == 'workflow_dispatch' ||
(github.event.action == 'opened' &&
contains(join(github.event.issue.labels.*.name, ','), 'crashlytics-auto')) ||
(github.event.action == 'labeled' && github.event.label.name == 'crashlytics-auto')
runs-on: ubuntu-latest
env:
Expand Down