Skip to content

Commit 1374fa9

Browse files
committed
Merge branch 'main' of https://github.com/annaweber830/App into fix-79952
2 parents afda142 + efd610b commit 1374fa9

2,884 files changed

Lines changed: 177598 additions & 112252 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.claude/agents/deploy-blocker-investigator.md

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
name: deploy-blocker-investigator
33
description: Investigates deploy blockers to find the causing PR and recommend resolution.
4-
tools: Glob, Grep, Read, Bash, BashOutput
4+
tools: Glob, Grep, Read, Write, Bash, BashOutput
55
model: inherit
66
---
77

@@ -114,11 +114,9 @@ See Decision Tree below for label actions.
114114

115115
### Step 7: Post comment and update labels
116116

117-
Post your findings (use single quotes for the body to handle special characters):
117+
Write the comment body to a temp file using the Write tool, then post it:
118118
```bash
119-
gh issue comment "$ISSUE_URL" --body '## 🔍 Investigation Summary
120-
...your comment here...
121-
'
119+
gh issue comment "$ISSUE_URL" --body-file /tmp/investigation-summary.md
122120
```
123121

124122
Remove label only if the decision tree warrants it:
@@ -129,6 +127,15 @@ removeDeployBlockerLabel.sh "$ISSUE_URL" DeployBlocker # For Frontend bugs
129127

130128
Call scripts by name only (e.g., `removeDeployBlockerLabel.sh`), not with full paths.
131129

130+
### Step 8: Assign contributors
131+
132+
If the primary causing PR has at least medium confidence, assign its author and approving reviewers to the deploy blocker issue. Only assign contributors from this single PR.
133+
134+
```bash
135+
gh pr view <PR_NUMBER> --json reviews
136+
gh issue edit "$ISSUE_URL" --add-assignee <logins>
137+
```
138+
132139
---
133140

134141
## Decision Tree
@@ -168,7 +175,7 @@ Choose ONE:
168175

169176
## Comment Format
170177

171-
Post ONE comment using this exact format:
178+
Use the Write tool to create `/tmp/investigation-summary.md` with the following markdown structure. Every field and heading must be present.
172179

173180
```markdown
174181
## 🔍 Investigation Summary
@@ -182,6 +189,7 @@ Post ONE comment using this exact format:
182189
Brief explanation of why this recommendation (1-2 sentences).
183190

184191

192+
**Assigned**: @author (PR author), @reviewer (approving reviewer) from highest-confidence causing PR only — omit if no causing PR identified
185193
**Labels**: [Describe any label changes made]
186194

187195
<details>
@@ -201,6 +209,8 @@ Technical explanation of what went wrong in the code.
201209

202210
</details>
203211
```
212+
213+
Then post with: `gh issue comment "$ISSUE_URL" --body-file /tmp/investigation-summary.md`
204214
---
205215

206216
## Constraints
@@ -213,7 +223,7 @@ Technical explanation of what went wrong in the code.
213223
- Make assumptions about code you haven't read
214224
- Recommend DEMOTE for bugs affecting core functionality (auth, payments, data loss)
215225
- Close the issue—only update labels and comment
216-
- Use heredocs, temp files, or shell redirects for comments
226+
- Use heredocs or shell redirects for comments
217227

218228
**DO:**
219229
- Always verify the causing PR touches the affected code before concluding

.claude/commands/investigate-deploy-blocker.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
allowed-tools: Bash(gh issue view:*),Bash(gh issue comment:*),Bash(gh issue list:*),Bash(gh pr view:*),Bash(gh pr list:*),Bash(gh pr diff:*),Bash(gh api:*),Bash(git log:*),Bash(git show:*),Bash(git blame:*),Bash(removeDeployBlockerLabel.sh:*),Glob,Grep,Read
2+
allowed-tools: Bash(gh issue view:*),Bash(gh issue comment:*),Bash(gh issue edit:*),Bash(gh issue list:*),Bash(gh pr view:*),Bash(gh pr list:*),Bash(gh pr diff:*),Bash(gh api:*),Bash(git log:*),Bash(git show:*),Bash(git blame:*),Bash(removeDeployBlockerLabel.sh:*),Glob,Grep,Read,Write
33
description: Investigate a deploy blocker issue to find the causing PR and recommend resolution
44
---
55

.claude/scripts/createInlineComment.sh

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# Secure proxy script to create an inline comment on a GitHub PR.
44
set -eu
55

6-
readonly ALLOWED_RULES_FILE="${GITHUB_WORKSPACE}/.claude/allowed-rules.txt"
6+
readonly ALLOWED_RULES_FILE="${ALLOWED_RULES_FILE:-${GITHUB_WORKSPACE}/.claude/allowed-rules.txt}"
77

88
# Print error and exit.
99
die() {
@@ -47,11 +47,12 @@ readonly LINE_ARG="${3:-}"
4747
validate_rule "$BODY_ARG"
4848
echo "Comment approved: $COMMENT_STATUS_REASON"
4949

50-
readonly FOOTER=$'\n\n---\n\nPlease rate this suggestion with 👍 or 👎 to help us improve! Reactions are used to monitor reviewer efficiency.'
51-
readonly COMMENT_BODY="${BODY_ARG}${FOOTER}"
52-
5350
COMMIT_ID=$(gh api "/repos/$GITHUB_REPOSITORY/pulls/$PR_NUMBER" --jq '.head.sha')
5451
readonly COMMIT_ID
52+
readonly SHORT_SHA="${COMMIT_ID:0:7}"
53+
54+
readonly FOOTER=$'\n\n---\n\n'"Reviewed at: [${SHORT_SHA}](https://github.com/${GITHUB_REPOSITORY}/commit/${COMMIT_ID}) | Please rate this suggestion with 👍 or 👎 to help us improve! Reactions are used to monitor reviewer efficiency."
55+
readonly COMMENT_BODY="${BODY_ARG}${FOOTER}"
5556

5657
PAYLOAD=$(jq -n \
5758
--arg body "$COMMENT_BODY" \

.claude/settings.json

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,21 @@
3838
"mcp__playwright__browser_wait_for",
3939
"mcp__playwright__browser_close",
4040
"mcp__playwright__browser_evaluate",
41-
"mcp__playwright__browser_handle_dialog"
41+
"mcp__playwright__browser_handle_dialog",
42+
"mcp__sentry__find_organizations",
43+
"mcp__sentry__find_projects",
44+
"mcp__sentry__find_releases",
45+
"mcp__sentry__find_teams",
46+
"mcp__sentry__get_doc",
47+
"mcp__sentry__get_event_attachment",
48+
"mcp__sentry__get_issue_details",
49+
"mcp__sentry__get_issue_tag_values",
50+
"mcp__sentry__get_trace_details",
51+
"mcp__sentry__search_docs",
52+
"mcp__sentry__search_events",
53+
"mcp__sentry__search_issue_events",
54+
"mcp__sentry__search_issues",
55+
"mcp__sentry__whoami"
4256
]
4357
},
4458
"enabledPlugins": {

.claude/skills/coding-standards/rules/clean-react-0-compiler.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ Manual memoization is therefore:
1818
The codebase enforces this via:
1919
- **Babel plugin**: `babel-plugin-react-compiler` in `babel.config.js`
2020
- **ESLint processor**: `eslint-plugin-react-compiler-compat` suppresses redundant lint rules when files compile successfully
21-
- **CI compliance check**: `scripts/react-compiler-compliance-check.ts` blocks PRs with manual memoization in new files
21+
- **CI compliance check**: `scripts/react-compiler-compliance-check.ts` enforces that new components/hooks compile and that existing compiled files don't regress
2222

2323
Reference: [React Compiler documentation](https://react.dev/learn/react-compiler)
2424

@@ -101,6 +101,8 @@ Before flagging, verify that the file actually compiles with React Compiler:
101101
check-compiler.sh <filepath>
102102
```
103103

104+
**IMPORTANT:** Run `check-compiler.sh` exactly as shown above - by name only, without an absolute path or `bash` prefix. The script is already on `$PATH`.
105+
104106
If the output contains **"Failed to compile"** for the file under review, the rule **does not apply** — the author may have no alternative to manual memoization until the compilation issue is resolved.
105107

106108
#### Condition

.claude/skills/coding-standards/rules/clean-react-1-composition-over-config.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -462,11 +462,11 @@ In all cases, the rule applies to: **new components**, **new features added to e
462462
- The optional prop is used for logic beyond just conditional rendering (e.g., computing derived values, passed to callbacks, used in multiple places within the component)
463463
- The component is a thin wrapper around a platform primitive (e.g., wrapping `TextInput`, `ScrollView`, `Pressable`) — these naturally pass through configuration props
464464
- Items come from **runtime data** (API responses, user-generated content, Onyx collections) — dynamic data must be mapped
465-
- The array is used with **list components** (e.g., `FlatList`, `SectionList`, or custom wrappers) — these require data arrays by design
465+
- The array is used with **list components** (e.g., `FlatList`, or custom wrappers) — these require data arrays by design
466466
- Items are truly **homogeneous** (same shape, same behavior, only values differ) and the count is **unbounded** (e.g., list of chat messages, search results)
467467
- The array is a **framework requirement** (e.g., React Navigation screen config, form validation rules)
468468
- The `ReactNode` prop is `children` itself — `children` is the foundation of composition, not configuration
469-
- The render function is a **list component callback** (`renderItem` on `FlatList`, `SectionList`, `DraggableList`) — these are framework requirements
469+
- The render function is a **list component callback** (`renderItem` on `FlatList`, `DraggableList`) — these are framework requirements
470470
- The render function receives **per-item runtime data** from a dynamic collection (e.g., `renderSuggestionMenuItem(item, index)`) — this is list-style rendering, not slot configuration
471471

472472
**Search Patterns** (hints for reviewers):

.claude/skills/coding-standards/rules/perf-1-no-spread-in-renderitem.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ title: No spread in list item's renderItem
3737

3838
Flag ONLY when ALL of these are true:
3939

40-
- Code is inside a renderItem function (function passed to FlatList, SectionList, etc.)
40+
- Code is inside a renderItem function (function passed to FlatList, etc.)
4141
- A spread operator (...) is used on an object
4242
- That object is being passed as a prop to a component
4343
- The spread creates a NEW object literal inline

.claude/skills/sentry/SKILL.md

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
---
2+
name: sentry
3+
description: Analyze Sentry issues, spans, crashes, and performance metrics. Use when user requests check in Sentry, asks about performance metrics and spans or asks about crash rates.
4+
---
5+
6+
# Sentry
7+
8+
## When to Use This Skill
9+
10+
Use Sentry skill when:
11+
- User requests any data from Sentry
12+
- User asks about performance metrics or span summary
13+
- User want to compare metrics between any date ranges
14+
- User asks about latest production crashes and issues
15+
- User want to investigate profiles or traces from production sessions
16+
17+
## Sentry MCP
18+
19+
The Sentry MCP server is configured in `.mcp.json` and gives Claude Code direct access to Sentry.
20+
21+
### Prerequisites
22+
23+
**Setup** (one-time per engineer): On first use, Claude Code will open a browser OAuth login to Sentry. Sign in and authorize — no manual token setup required.
24+
25+
### Available MCP Tools
26+
27+
Use these tools for data analysis:
28+
29+
| Tool | Purpose |
30+
|------|---------|
31+
| `mcp__sentry__find_releases` | Find release versions for scoping queries |
32+
| `mcp__sentry__search_issues` | Search for errors/crashes by query, project, date range |
33+
| `mcp__sentry__search_events` | Query raw events/spans (performance data, durations) |
34+
| `mcp__sentry__search_issue_events` | Get individual events for a known issue ID |
35+
| `mcp__sentry__get_issue_tag_values` | Inspect tag distributions (e.g. device, version) on an issue |
36+
| `mcp__sentry__get_sentry_resource` | Fetch a specific Sentry resource by URL/ID |
37+
38+
**Do not use** `mcp__sentry__analyze_issue_with_seer` — AI analysis is out of scope for this skill.
39+
40+
Always use:
41+
- **org slug**: `expensify`
42+
- **project slug**: `app`
43+
44+
## Example uses
45+
46+
- "Search Sentry for crashes in the last 24h related to expense creation"
47+
- "Get details on Sentry issue APP-123"
48+
- "Compare P90 of ManualAppStartup durations between last two weeks"

.env.example

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,5 +44,6 @@ FB_PROJECT_ID=YOUR_PROJECT_ID
4444
GITHUB_TOKEN=YOUR_TOKEN
4545
OPENAI_API_KEY=YOUR_TOKEN
4646

47+
SENTRY_DSN=https://7b463fb4d4402d342d1166d929a62f4e@o4510228013121536.ingest.us.sentry.io/4510228107427840
4748
SENTRY_AUTH_TOKEN=SENTRY_AUTH_TOKEN
4849
SENTRY_ALLOW_FAILURE=true

.env.production

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ PUSHER_APP_KEY=268df511a204fbb60884
77
USE_WEB_PROXY=false
88
ENVIRONMENT=production
99
SEND_CRASH_REPORTS=true
10-
1110
FB_API_KEY=AIzaSyBrLKgCuo6Vem6Xi5RPokdumssW8HaWBow
1211
FB_APP_ID=1:1008697809946:web:08de4ecb7656b7235445a3
1312
FB_PROJECT_ID=expensify-mobile-app

0 commit comments

Comments
 (0)