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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -107,3 +107,4 @@ samples/*/.env
# Auto-generated by dotagents โ€” do not commit these files.
agents.lock
.agents/.gitignore
tsconfig.tsbuildinfo
2 changes: 2 additions & 0 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
enableScripts: true

nmHoistingLimits: workspaces

nodeLinker: node-modules
20 changes: 19 additions & 1 deletion dev-packages/e2e-tests/cli.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,25 @@ if (actions.includes('create')) {
fs.writeFileSync(appPackageJsonPath, JSON.stringify(appPackageJson, null, 2) + '\n');

// original yarnrc contains the exact yarn version which causes corepack to fail to install yarn v3
fs.writeFileSync(`${appDir}/.yarnrc.yml`, 'nodeLinker: node-modules', { encoding: 'utf-8' });
fs.writeFileSync(`${appDir}/.yarnrc.yml`, 'nodeLinker: node-modules\n', { encoding: 'utf-8' });

// The generated app pins its own yarn version (varies by RN version: e.g. v3 for
// older RN, v4 for newer). yarn 4 quarantines any package newer than
// npmMinimalAgeGate (default 1 day) โ€” and auto-enables that gate on public-PR CI โ€”
// so a just-published first-party @sentry/* version (e.g. right after a JS SDK bump)
// resolved fresh from this app's empty lockfile fails the install. Disable the gate,
// but only when the app's yarn supports the setting: yarn 3 hard-errors on unknown
// settings, and it has no age gate to begin with. Probe support rather than guess a
// version threshold.
const appYarnSupportsAgeGate =
execSync(`yarn config npmMinimalAgeGate > /dev/null 2>&1; echo $?`, {
cwd: appDir,
env: env,
encoding: 'utf-8',
}).trim() === '0';
if (appYarnSupportsAgeGate) {
fs.appendFileSync(`${appDir}/.yarnrc.yml`, 'npmMinimalAgeGate: 0\n', { encoding: 'utf-8' });
}
// yarn v3 won't install dependencies in a sub project without a yarn.lock file present
fs.writeFileSync(`${appDir}/yarn.lock`, '');

Expand Down
8 changes: 7 additions & 1 deletion dev-packages/type-check/run-type-check.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,13 @@ cd "${__dirpath}/ts3.8-test"
yalc add @sentry/expo-upload-sourcemaps
yalc add @sentry/react-native

yarn install
# Disable yarn 4's release-age gate for this fresh install. The yalc-linked
# @sentry/react-native pulls transitive @sentry/* deps that get resolved fresh, so a
# just-published SDK version (e.g. right after a JS SDK bump) would be quarantined
# (default npmMinimalAgeGate is 1 day, and hardened mode auto-enables on public-PR CI)
# and fail the install. This workspace always runs on the repo's yarn 4, so the
# setting is always valid here.
YARN_NPM_MINIMAL_AGE_GATE=0 yarn install

# Re-add yalc packages to ensure they are in node_modules (yarn might have removed them)
yalc add @sentry/expo-upload-sourcemaps
Expand Down
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -134,9 +134,10 @@
"socks": "^2.8.8",
"@appium/support@npm:7.0.6/uuid": "^13.0.1",
"node-simctl@npm:8.1.6/uuid": "^13.0.1",
"shell-quote": "^1.8.4"
"shell-quote": "^1.8.4",
"downlevel-dts@npm:0.11.0/typescript": "5.9.3"
},
"version": "0.0.0",
"name": "sentry-react-native",
"packageManager": "yarn@3.6.4+sha512.e70835d4d6d62c07be76b3c1529cb640c7443f0fe434ef4b6478a5a399218cbaf1511b396b3c56eb03bc86424cff2320f6167ad2fde273aa0df6e60b7754029f"
"packageManager": "yarn@4.17.0+sha512.c2957de2f9025ab14d63b24d0d8be1f1655810e22c341042c27f7ecd017b180ec12db73d69ac366d71b304ef9f069349ce462de96f04f8f1da317f4f762c95ae"
}
Loading
Loading