Skip to content

Commit 3b97e48

Browse files
Merge branch 'main' into 9.x.x
Resolve conflicts in CHANGELOG.md, AnrV2Integration, TombstoneIntegration, and two files that 9.x.x added in directories main moved. Co-Authored-By: Nelson Osacky <nelson.osacky@sentry.io>
2 parents 7178358 + ea8900f commit 3b97e48

272 files changed

Lines changed: 2006 additions & 716 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/skills/btrace-perfetto/SKILL.md‎

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,11 @@ If no arguments are provided, ask the user what they want to trace and which bra
5858

5959
## Step 2: Integrate btrace into Sample App
6060

61-
The sample app is at `sentry-samples/sentry-samples-android/`.
61+
The sample app is at `sentry-android-integration-tests/sentry-samples-android/`.
6262

6363
### 2a: Add btrace dependency
6464

65-
In `sentry-samples/sentry-samples-android/build.gradle.kts`, add to the `dependencies` block:
65+
In `sentry-android-integration-tests/sentry-samples-android/build.gradle.kts`, add to the `dependencies` block:
6666

6767
```kotlin
6868
implementation("com.bytedance.btrace:rhea-inhouse:3.0.0")
@@ -98,7 +98,7 @@ protected void attachBaseContext(Context base) {
9898

9999
### 2d: Add ProGuard keep rules (release builds only)
100100

101-
Only needed when building release. In `sentry-samples/sentry-samples-android/proguard-rules.pro`, add:
101+
Only needed when building release. In `sentry-android-integration-tests/sentry-samples-android/proguard-rules.pro`, add:
102102

103103
```
104104
-keep class com.bytedance.rheatrace.** { *; }
@@ -112,13 +112,13 @@ The first rule prevents R8 from stripping btrace's HTTP server classes (fails wi
112112
Prefer **debug builds** — they provide richer tracing instrumentation (Handler, MessageQueue, Monitor:Lock slices visible) which is essential for comparing internal SDK behavior. Use the default 1kHz btrace sampling rate for debug builds.
113113

114114
```bash
115-
./gradlew :sentry-samples:sentry-samples-android:installDebug
115+
./gradlew -p sentry-android-integration-tests :sentry-samples-android:installDebug
116116
```
117117

118118
**Release builds** are useful when you need to measure real-world performance without StrictMode/debuggable overhead or with R8 optimizations. Require the ProGuard keep rules from step 2d. Use `-sampleInterval 333000` (333μs / 3kHz) for finer granularity since release code runs faster.
119119

120120
```bash
121-
./gradlew :sentry-samples:sentry-samples-android:installRelease
121+
./gradlew -p sentry-android-integration-tests :sentry-samples-android:installRelease
122122
```
123123

124124
## Step 4: Capture Trace
@@ -170,9 +170,9 @@ When capturing a second branch:
170170
1. Stash the btrace integration changes:
171171
```bash
172172
git stash push -m "btrace integration" -- \
173-
sentry-samples/sentry-samples-android/build.gradle.kts \
174-
sentry-samples/sentry-samples-android/src/main/java/io/sentry/samples/android/MyApplication.java \
175-
sentry-samples/sentry-samples-android/proguard-rules.pro
173+
sentry-android-integration-tests/sentry-samples-android/build.gradle.kts \
174+
sentry-android-integration-tests/sentry-samples-android/src/main/java/io/sentry/samples/android/MyApplication.java \
175+
sentry-android-integration-tests/sentry-samples-android/proguard-rules.pro
176176
```
177177
2. Checkout the other branch
178178
3. Pop the stash: `git stash pop`

‎.claude/skills/create-java-pr/SKILL.md‎

Lines changed: 20 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -55,17 +55,7 @@ If the user explicitly says "stack", "stacked PR", or provides numbered stack ti
5555

5656
## Step 1: Ensure Feature Branch
5757

58-
```bash
59-
git branch --show-current
60-
```
61-
62-
If on `main` or `master`, create and switch to a new branch:
63-
64-
```bash
65-
git checkout -b <type>/<short-description>
66-
```
67-
68-
Derive the branch name from the changes being made. Use `feat/`, `fix/`, `ref/`, etc. matching the commit type conventions.
58+
If on `main` or `master`, invoke the `sentry-skills:create-branch` skill.
6959

7060
**For stacked PRs:** For the first PR in a new stack, first create and push the collection branch (see `references/stacked-prs.md` § "Why a Collection Branch"), then branch the PR off it. For subsequent PRs, branch off the previous stack branch. Give every branch in the stack a shared prefix naming the feature, with a descriptive suffix per PR.
7161

@@ -89,13 +79,7 @@ Check for uncommitted changes:
8979
git status --porcelain
9080
```
9181
92-
If there are uncommitted changes, invoke the `sentry-skills:commit` skill to stage and commit them following [Sentry commit message conventions](https://develop.sentry.dev/engineering-practices/commit-messages/):
93-
94-
```
95-
<type>(<scope>): <subject>
96-
```
97-
98-
Allowed types: `feat`, `fix`, `ref`, `chore`, `docs`, `test`, `perf`, `build`, `ci`, `style`, `meta`, `license`
82+
If there are uncommitted changes, invoke the `sentry-skills:commit` skill to stage and commit them.
9983
10084
**Important:** When staging, ignore changes that are only relevant for local testing and should not be part of the PR. Common examples:
10185
@@ -121,28 +105,30 @@ If the push fails due to diverged history, ask the user how to proceed rather th
121105
122106
## Step 5: Create PR
123107
124-
Invoke the `sentry-skills:create-pr` skill to create a draft PR.
108+
Invoke the `sentry-skills:pr-writer` skill to create a draft PR.
125109
126-
Read `.github/pull_request_template.md` and use it as the PR body structure — it is the single source
127-
of truth for the sections and checklist, so never reproduce it from memory. Fill in each section based
128-
on the changes being PR'd, drop the HTML comment hints, and check any checklist items that apply.
110+
Read `.github/pull_request_template.md` and use it as the PR body structure instead of pr-writer's
111+
default body shape — it is the single source of truth for the sections and checklist, so never
112+
reproduce it from memory. Fill in each section based on the changes being PR'd, drop the HTML
113+
comment hints, and check any checklist items that apply.
129114
130-
**PR title format** — same as the commit subject (Step 3):
115+
Write the body to `/tmp/pr-body-<branch>.md`, with each `/` in the branch name replaced by `-`, not
116+
to pr-writer's `/tmp/pr-body.md`: that file outlives sessions and can still hold another PR's body.
117+
Only after the write succeeds, pass that file to `gh pr create` in place of pr-writer's:
131118

132-
```
133-
<type>(<scope>): <Subject>
119+
```bash
120+
gh pr create --draft --title '<title>' --body-file /tmp/pr-body-<branch>.md
134121
```
135122

136-
Examples:
137-
- `feat(core): Add structured logging support`
138-
- `fix(android): Prevent crash on API 21 when registering receiver`
123+
If the change needs no changelog entry (see Step 6), make `#skip-changelog` the last line of the
124+
body to disable the changelog CI check.
139125

140126
**For stacked PRs:**
141127

142128
- Pass `--base <previous-stack-branch>` so the PR targets the previous branch (first PR in a stack targets the collection branch).
143129
- Use the stacked PR title format: `<type>(<scope>): [<Topic> <N>] <Subject>` (see `references/stacked-prs.md` § "PR Title Naming").
144130
- Include the stack list at the top of the PR body, before the `## :scroll: Description` section (see `references/stacked-prs.md` § "Stack List in PR Description" for the format).
145-
- Add a merge method reminder at the very end of the PR body (see `references/stacked-prs.md` § "Stack List in PR Description" for the exact text). This only applies to stack PRs, not the collection branch PR.
131+
- Add a merge method reminder at the end of the PR body, above any `#skip-changelog` (see `references/stacked-prs.md` § "Stack List in PR Description" for the exact text). This only applies to stack PRs, not the collection branch PR.
146132

147133
Then continue to Step 5.5 (stacked PRs only) or Step 6.
148134

@@ -156,7 +142,8 @@ Edit each body using the procedure in § "Editing PR Descriptions" below.
156142

157143
## Step 6: Update Changelog
158144

159-
First, determine whether a changelog entry is needed. **Skip this step** (and go straight to "No changelog needed" below) if the changes are not user-facing, for example:
145+
Decide whether a changelog entry is needed before Step 5, which adds `#skip-changelog` to the PR
146+
body when it is not. **Skip this step** if the changes are not user-facing, for example:
160147

161148
- Test-only changes (new tests, test refactors, test fixtures)
162149
- CI/CD or build configuration changes
@@ -190,7 +177,7 @@ Create the subsection under `## Unreleased` if it does not already exist.
190177
- <Short description of the change> ([#<PR_NUMBER>](https://github.com/getsentry/sentry-java/pull/<PR_NUMBER>))
191178
```
192179
193-
Use the PR number returned by `sentry-skills:create-pr`. Match the style of existing entries — sentence case, ending with the PR link, no trailing period.
180+
Use the number of the PR created in Step 5. Match the style of existing entries — sentence case, ending with the PR link, no trailing period.
194181
195182
#### Commit and push
196183
@@ -202,16 +189,11 @@ git commit -m "changelog"
202189
git push
203190
```
204191
205-
### No changelog needed
206-
207-
If no changelog entry is needed, append `#skip-changelog` to the end of the PR description to disable
208-
the changelog CI check, using the procedure in § "Editing PR Descriptions" below.
209-
210192
## Editing PR Descriptions
211193
212194
Do not use shell redirects (`>`, `>>`), pipes (`|`), or compound commands (`&&`, `||`). These create
213195
compound shell expressions that won't match permission patterns. Instead:
214196
215197
1. Read the body with `gh pr view <PR_NUMBER> --json body --jq '.body'` (output is returned directly)
216-
2. Use the `Write` tool to save it to `/tmp/pr-body.md`, and the `Edit` tool to modify it
217-
3. Update with `gh pr edit <PR_NUMBER> --body-file /tmp/pr-body.md`
198+
2. Use the `Write` tool to save it to `/tmp/pr-body-<PR_NUMBER>.md`, and the `Edit` tool to modify it
199+
3. Once the write succeeds, update with `gh pr edit <PR_NUMBER> --body-file /tmp/pr-body-<PR_NUMBER>.md`

‎.claude/skills/create-java-pr/references/stacked-prs.md‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ git commit --allow-empty -m "collection: <topic>"
2626

2727
Push it and open its PR against `main` right away — it is the PR the whole stack is eventually
2828
squash-merged through, and it carries the stack list like every other PR. Give it a plain title
29-
(`<type>(<scope>): <Topic>`, no `[<Topic> <N>]` bracket) and no merge method reminder.
29+
(`<type>(<scope>): <Topic>`, no `[<Topic> <N>]` bracket) and no merge method reminder. Create it
30+
with the `gh pr create` command and per-branch body file from `SKILL.md` § "Step 5: Create PR".
3031

3132
## Rules That Will Destroy a Stack If Broken
3233

@@ -76,7 +77,7 @@ off any PR body rather than guessing from branch names, which may use different
7677
No status column — GitHub already shows that. The `---` separates the stack list from the rest of
7778
the description.
7879

79-
**Merge method reminder:** on stack PRs (not the collection branch PR), end the description with:
80+
**Merge method reminder:** on stack PRs (not the collection branch PR), end the description, above any `#skip-changelog`, with:
8081

8182
```markdown
8283
> ⚠️ **Merge this PR using a merge commit** (not squash). Only the collection branch is squash-merged into main.

‎.cursor/rules/e2e_tests.mdc‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,9 @@ and server. The `io.sentry.otel-agent-tests` plugin in `build-logic` gives the S
6060
an `agentFixture` source set with the app, the `integrationTestOtelAgent` suite and the built agent
6161
jar; each module adds only the dependencies of its Spring Boot line. `AgentApp` starts the app once
6262
per test JVM in a child process, with `ChildJvmApp` and the agent jar passed through
63-
`ChildJvmTestArguments`. The suite's task runs with the agent initializing Sentry, and
64-
`integrationTestOtelAgentWithoutAutoInit` runs the same tests with the Spring Boot starter doing
65-
it. Gradle runs the two in parallel. `otelAgentTests()` in a `springBootMatrix` block registers
63+
`ChildJvmTestArguments`. The suite's task runs with the agent initializing Sentry, and its second
64+
target, `integrationTestOtelAgentWithoutAutoInit`, runs the same tests with the Spring Boot starter
65+
doing it. Gradle runs the two in parallel. `otelAgentTests()` in a `springBootMatrix` block registers
6666
both on each version.
6767

6868
## Running them

‎.github/dependabot.yml‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ updates:
1717
ignore:
1818
- dependency-name: "org.springframework.boot*"
1919
- dependency-name: "io.opentelemetry*"
20+
# Servlet 3.1 is the minimum supported API and must remain the production compile target.
21+
- dependency-name: "javax.servlet:javax.servlet-api"
2022
# DGS 5+ needs Spring Boot 3; the sample is on Spring Boot 2.
2123
- dependency-name: "com.netflix.graphql.dgs*"
2224
commit-message:

‎.github/workflows/agp-matrix.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
3333

3434
- name: Setup Java Version
35-
uses: actions/setup-java@77dd5b2ce225ea11469928ac317850245a74ae78 # v6.2.0
35+
uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # v6.3.0
3636
with:
3737
distribution: 'temurin'
3838
java-version: '21'

‎.github/workflows/build.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
ref: ${{ github.event.pull_request.head.sha || github.sha }}
2323

2424
- name: Setup Java Version
25-
uses: actions/setup-java@77dd5b2ce225ea11469928ac317850245a74ae78 # v6.2.0
25+
uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # v6.3.0
2626
with:
2727
distribution: 'temurin'
2828
java-version: '21'

‎.github/workflows/codeql-analysis.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
2121

2222
- name: Setup Java Version
23-
uses: actions/setup-java@77dd5b2ce225ea11469928ac317850245a74ae78 # v6.2.0
23+
uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # v6.3.0
2424
with:
2525
distribution: 'temurin'
2626
java-version: '21'
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: Compose UI Matrix
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
9+
concurrency:
10+
group: ${{ github.workflow }}-${{ github.ref }}
11+
cancel-in-progress: true
12+
13+
jobs:
14+
compose-ui-matrix:
15+
timeout-minutes: 30
16+
runs-on: ubuntu-latest
17+
name: Compose UI Matrix
18+
19+
steps:
20+
- name: Checkout Repo
21+
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
22+
23+
- name: Setup Java Version
24+
uses: actions/setup-java@77dd5b2ce225ea11469928ac317850245a74ae78 # v6.2.0
25+
with:
26+
distribution: 'temurin'
27+
java-version: '21'
28+
29+
- name: Setup Gradle
30+
uses: gradle/actions/setup-gradle@8da46b539cd8fe6ab27ca75128919a18d757604c # v6.4.1
31+
32+
# Runs every version in gradle/compose-ui-versions.json; --continue reports each failing one.
33+
- name: Run Session Replay unit tests
34+
run: ./gradlew :sentry-android-replay:composeUiTest --continue
35+
36+
- name: Upload test results
37+
if: always()
38+
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7
39+
with:
40+
name: test-results-compose-ui
41+
path: |
42+
sentry-android-replay/build/reports/*
43+
sentry-android-replay/build/test-results/**/*.xml
44+
45+
- name: Test Report
46+
uses: phoenix-actions/test-reporting@7317eea6e13c47348dd0bb318669485157c518d6 # pin@v16
47+
if: always()
48+
with:
49+
name: JUnit Compose UI
50+
path: |
51+
sentry-android-replay/build/test-results/**/*.xml
52+
reporter: java-junit
53+
output-to: step-summary
54+
fail-on-error: false

‎.github/workflows/enforce-license-compliance.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
uses: gradle/actions/setup-gradle@8da46b539cd8fe6ab27ca75128919a18d757604c # v6.4.1
1515

1616
- name: Set up Java
17-
uses: actions/setup-java@77dd5b2ce225ea11469928ac317850245a74ae78 # v6.2.0
17+
uses: actions/setup-java@d1374f8ac74474200d16ef8ecee22c7ae7a51880 # v6.3.0
1818
with:
1919
distribution: 'temurin'
2020
java-version: '21'

0 commit comments

Comments
 (0)