Skip to content

Commit e6e5918

Browse files
Merge branch 'main' into sync/main-to-9.x.x-2026-11-17
Sync main (9feef75) into 9.x.x and resolve the merge conflicts. Co-Authored-By: Nelson Osacky <nelson.osacky@sentry.io>
2 parents da410bc + 9feef75 commit e6e5918

729 files changed

Lines changed: 14953 additions & 6644 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.

‎.craft.yml‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,11 @@ targets:
119119
packageUrl: https://central.sonatype.com/artifact/io.sentry/sentry-android-ndk
120120
mainDocsUrl: https://docs.sentry.io/platforms/android/
121121
apiDocsUrl: https://javadoc.io/doc/io.sentry
122+
maven:io.sentry:sentry-android-ndk-outproc:
123+
name: io.sentry:sentry-android-ndk-outproc
124+
packageUrl: https://central.sonatype.com/artifact/io.sentry/sentry-android-ndk-outproc
125+
mainDocsUrl: https://docs.sentry.io/platforms/android/configuration/using-ndk/
126+
apiDocsUrl: https://javadoc.io/doc/io.sentry
122127
maven:io.sentry:sentry-android-timber:
123128
name: io.sentry:sentry-android-timber
124129
packageUrl: https://central.sonatype.com/artifact/io.sentry/sentry-android-timber

‎.cursor/rules/e2e_tests.mdc‎

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,11 +56,14 @@ match on values only they produce.
5656
## The OpenTelemetry agent
5757

5858
The agent must not run in the test's JVM, because it would instrument the test's own HTTP client
59-
and server. The Spring Boot modules have an `agentFixture` source set with the app. `AgentApp`
60-
starts it once per test JVM in a child process, with `ChildJvmApp` and the agent jar passed through
59+
and server. The `io.sentry.otel-agent-tests` plugin in `build-logic` gives the Spring Boot modules
60+
an `agentFixture` source set with the app, the `integrationTestOtelAgent` suite and the built agent
61+
jar; each module adds only the dependencies of its Spring Boot line. `AgentApp` starts the app once
62+
per test JVM in a child process, with `ChildJvmApp` and the agent jar passed through
6163
`ChildJvmTestArguments`. The suite's task runs with the agent initializing Sentry, and
6264
`integrationTestOtelAgentWithoutAutoInit` runs the same tests with the Spring Boot starter doing
63-
it. Gradle runs the two in parallel.
65+
it. Gradle runs the two in parallel. `otelAgentTests()` in a `springBootMatrix` block registers
66+
both on each version.
6467

6568
## Running them
6669

‎.github/ISSUE_TEMPLATE/bug_report_android.yml‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ body:
1010
options:
1111
- sentry-android
1212
- sentry-android-ndk
13+
- sentry-android-ndk-outproc
1314
- sentry-android-timber
1415
- sentry-android-fragment
1516
- sentry-android-navigation3

‎.github/dependabot.yml‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,18 +7,18 @@ registries:
77
password: dummy # Required by dependabot
88
updates:
99
- package-ecosystem: "gradle"
10-
# The root build doesn't include the separate sample and test builds.
11-
directories:
12-
- "/"
13-
- "/sentry-samples/sentry-samples-android"
14-
- "/sentry-android-integration-tests"
15-
- "/sentry-samples"
10+
# The separate sample and test builds read this build's version catalog, so one directory
11+
# covers them. Listing them too opens one PR per directory for the same bump.
12+
directory: "/"
1613
registries:
1714
- gradle-plugin-portal
1815
schedule:
1916
interval: "daily"
2017
ignore:
2118
- dependency-name: "org.springframework.boot*"
19+
- dependency-name: "io.opentelemetry*"
20+
# DGS 5+ needs Spring Boot 3; the sample is on Spring Boot 2.
21+
- dependency-name: "com.netflix.graphql.dgs*"
2222
commit-message:
2323
prefix: "chore(deps)"
2424
- package-ecosystem: "github-actions"

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,15 @@ jobs:
1717
strategy:
1818
fail-fast: false
1919
matrix:
20-
agp: [ '9.0.0', '9.2.1', '9.4.0' ]
20+
agp: [ '9.0.0', '9.4.0', '9.5.1' ]
2121
integrations: [ true, false ]
2222

2323
name: AGP Matrix Release - AGP ${{ matrix.agp }} - Integrations ${{ matrix.integrations }}
2424
env:
2525
VERSION_AGP: ${{ matrix.agp }}
2626
APPLY_SENTRY_INTEGRATIONS: ${{ matrix.integrations }}
2727
# Upload replay snapshots from one cell only. Forks don't have access to the upload secret.
28-
UPLOAD_REPLAY_SNAPSHOTS: ${{ matrix.agp == '9.4.0' && matrix.integrations && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository) }}
28+
UPLOAD_REPLAY_SNAPSHOTS: ${{ matrix.agp == '9.5.1' && matrix.integrations && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository) }}
2929

3030
steps:
3131
- name: Checkout Repo

‎.github/workflows/danger.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ jobs:
88
danger:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: getsentry/github-workflows/danger@959162c159b866489d3fabe93327f48f9b8cb7ee # v3
11+
- uses: getsentry/github-workflows/danger@36529d71129a14967bea1fb81bcaf2a5943cf877 # v3

‎.github/workflows/pr-risk-jev.yml‎

Lines changed: 120 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,120 @@
1+
name: PR Risk (Jev)
2+
3+
on:
4+
pull_request_target:
5+
types: [opened, synchronize, reopened, ready_for_review, edited]
6+
workflow_dispatch:
7+
inputs:
8+
pr_number:
9+
description: Pull request number to analyze
10+
required: true
11+
type: number
12+
13+
permissions:
14+
contents: read
15+
pull-requests: write
16+
17+
concurrency:
18+
group: pr-risk-jev-${{ github.event.pull_request.number || inputs.pr_number }}
19+
cancel-in-progress: true
20+
21+
jobs:
22+
risk:
23+
name: PR risk (Jev)
24+
runs-on: ubuntu-latest
25+
timeout-minutes: 10
26+
if: github.event_name == 'workflow_dispatch' || github.event.pull_request.draft == false
27+
steps:
28+
# The Action reads PR Git objects without checking out or executing PR code.
29+
- name: Classify PR risk
30+
id: risk
31+
uses: getsentry/pr-risk-action@1cdeab5ada06969e5376666b3a79f444c2f41a67 # main
32+
env:
33+
AI_GATEWAY_API_KEY: ${{ secrets.AI_GATEWAY_API_KEY }}
34+
with:
35+
repo: ${{ github.repository }}
36+
pr-number: ${{ github.event.pull_request.number || inputs.pr_number }}
37+
expected-head-sha: ${{ github.event.pull_request.head.sha }}
38+
result-path: risk-pr-result.json
39+
40+
- name: Publish risk label
41+
if: ${{ !cancelled() && steps.risk.outcome != 'skipped' }}
42+
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
43+
env:
44+
PR_NUMBER: ${{ github.event.pull_request.number || inputs.pr_number }}
45+
with:
46+
script: |
47+
// Only this trusted workflow publishes labels; PR source is never executed.
48+
const fs = require('node:fs');
49+
if (!fs.existsSync('risk-pr-result.json')) {
50+
core.warning('Risk analysis did not produce a result; no label was published.');
51+
return;
52+
}
53+
const result = JSON.parse(fs.readFileSync('risk-pr-result.json', 'utf8'));
54+
const prNumber = Number(process.env.PR_NUMBER);
55+
const repo = context.repo;
56+
const colors = { low: '0E8A16', medium: 'FBCA04', high: 'B60205' };
57+
const riskLabels = Object.keys(colors).map(risk => `risk: ${risk}`);
58+
if (!Number.isSafeInteger(prNumber) || prNumber <= 0
59+
|| result.number !== prNumber || result.repo !== `${repo.owner}/${repo.repo}`
60+
|| typeof result.status !== 'string'
61+
|| (result.status === 'ok' && !Object.hasOwn(colors, result.risk_label))) {
62+
throw new Error('Risk result does not match this PR or a valid risk class.');
63+
}
64+
const snapshot = result.snapshot;
65+
if (result.status === 'pr_changed' || !snapshot?.source_head_sha || !snapshot?.source_base_sha) {
66+
core.warning('Risk analysis has no current revision; no label was published.');
67+
return;
68+
}
69+
const { data: pr } = await github.rest.pulls.get({ ...repo, pull_number: prNumber });
70+
if (pr.state !== 'open' || pr.head.sha !== snapshot.source_head_sha
71+
|| pr.base.sha !== snapshot.source_base_sha) {
72+
core.warning('PR changed after risk analysis; no label was published.');
73+
return;
74+
}
75+
const target = result.status === 'ok' ? `risk: ${result.risk_label}` : null;
76+
const existing = pr.labels.map(label => label.name);
77+
if (target && !existing.includes(target)) {
78+
try {
79+
await github.rest.issues.getLabel({ ...repo, name: target });
80+
} catch (error) {
81+
if (error.status !== 404) throw error;
82+
try {
83+
await github.rest.issues.createLabel({
84+
...repo, name: target, color: colors[result.risk_label],
85+
description: `PR risk score: ${result.risk_label}`,
86+
});
87+
} catch (error) {
88+
if (error.status !== 422) throw error;
89+
// Another PR may have created the shared repository label.
90+
await github.rest.issues.getLabel({ ...repo, name: target });
91+
}
92+
}
93+
await github.rest.issues.addLabels({ ...repo, issue_number: prNumber, labels: [target] });
94+
}
95+
// A failed classification must not leave an earlier low/medium/high verdict.
96+
for (const name of existing.filter(name => riskLabels.includes(name) && name !== target)) {
97+
try {
98+
await github.rest.issues.removeLabel({ ...repo, issue_number: prNumber, name });
99+
} catch (error) {
100+
if (error.status !== 404) throw error;
101+
}
102+
}
103+
const { data: latest } = await github.rest.pulls.get({ ...repo, pull_number: prNumber });
104+
if (target && (latest.state !== 'open' || latest.head.sha !== pr.head.sha
105+
|| latest.base.sha !== pr.base.sha || latest.title !== pr.title || latest.body !== pr.body)) {
106+
await github.rest.issues.removeLabel({ ...repo, issue_number: prNumber, name: target });
107+
core.warning('PR changed while publishing; removed the outdated risk label.');
108+
return;
109+
}
110+
if (!target) core.warning(`PR remains unclassified: ${result.status}. Previous risk labels were cleared.`);
111+
core.info(target ? `Published ${target}` : 'No risk label published.');
112+
113+
- name: Upload risk result
114+
if: always()
115+
uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7
116+
with:
117+
name: pr-risk-jev-${{ github.event.pull_request.number || inputs.pr_number }}
118+
path: risk-pr-result.json
119+
if-no-files-found: warn
120+
retention-days: 30

‎.github/workflows/release.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ jobs:
3333
# Needs to be set, otherwise git describe --tags will fail with: No names found, cannot describe anything
3434
fetch-depth: 0
3535
- name: Prepare release
36-
uses: getsentry/craft@9567926a606072678ef367b02445c4f99f374795 # 3.11.2
36+
uses: getsentry/craft@0da9309228741a4c300d3c87ed7dcafa8f703525 # 3.12.0
3737
env:
3838
GITHUB_TOKEN: ${{ steps.token.outputs.token }}
3939
with:

‎.github/workflows/update-deps.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
native:
1919
runs-on: ubuntu-latest
2020
steps:
21-
- uses: getsentry/github-workflows/updater@959162c159b866489d3fabe93327f48f9b8cb7ee # v3
21+
- uses: getsentry/github-workflows/updater@36529d71129a14967bea1fb81bcaf2a5943cf877 # v3
2222
with:
2323
path: scripts/update-sentry-native-ndk.sh
2424
name: Native SDK

‎.github/workflows/validate-pr.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
permissions:
1111
pull-requests: write
1212
steps:
13-
- uses: getsentry/github-workflows/validate-pr@959162c159b866489d3fabe93327f48f9b8cb7ee # v3
13+
- uses: getsentry/github-workflows/validate-pr@36529d71129a14967bea1fb81bcaf2a5943cf877 # v3
1414
with:
1515
app-id: ${{ vars.SDK_MAINTAINER_BOT_APP_ID }}
1616
private-key: ${{ secrets.SDK_MAINTAINER_BOT_PRIVATE_KEY }}

0 commit comments

Comments
 (0)