From d2f96840022e96c0a31c522a4f9891e6fbf167f0 Mon Sep 17 00:00:00 2001 From: "sentry-junior[bot]" <264270552+sentry-junior[bot]@users.noreply.github.com> Date: Sat, 5 Dec 2026 04:24:43 +0000 Subject: [PATCH 1/2] docs(cli): Document Homebrew tap trust and the Docker 3 tag for v3 users Homebrew 6 and later don't follow the sentry-cli -> sentry formula rename under tap trust, so the old name fails to install and existing installs stay on 3.8.2. Point v4 users at the full formula name and v3 users at the sentry-cli cask. In the Docker section, point v3 users at getsentry/sentry-cli:3 and show COPY and GitLab CI examples for v4, which has no shell. Co-Authored-By: BYK <126780+BYK@users.noreply.github.com> --- .../src/content/docs/migrating-from-v3.md | 59 ++++++++++++++++++- 1 file changed, 56 insertions(+), 3 deletions(-) diff --git a/apps/cli-docs/src/content/docs/migrating-from-v3.md b/apps/cli-docs/src/content/docs/migrating-from-v3.md index 915cd1ff9..ddceb65ce 100644 --- a/apps/cli-docs/src/content/docs/migrating-from-v3.md +++ b/apps/cli-docs/src/content/docs/migrating-from-v3.md @@ -75,7 +75,7 @@ installs `sentry-cli`. Pin the major version to stay on v3. | v3 channel | What a v4 upgrade does | Stay on v3 | |------------|------------------------|------------| | npm `@sentry/cli` | Installs `@sentry/cli@4`, the `sentry` package under the old name. It is deprecated: switch to `sentry`. | `@sentry/cli@^3` | -| Homebrew `getsentry/tools/sentry-cli` | The formula is renamed to `getsentry/tools/sentry`. `brew update` moves your install to it, and `brew upgrade` installs v4. | `brew pin sentry-cli` before updating | +| Homebrew `getsentry/tools/sentry-cli` | The formula is renamed to `getsentry/tools/sentry`. Homebrew 6 and later don't follow the rename; see [Homebrew](#homebrew). | `brew install --cask sentry-cli` | | PyPI `sentry-cli` | Installs the standalone v4 binary as `sentry`. | `sentry-cli<4` | | `downloads.sentry-cdn.com/sentry-cli//` | v4 versions hold the v4 binaries, named like `sentry-linux-x64` and `sentry-darwin-arm64.gz`. | Use a 3.x version in the URL | | Release registry `app:sentry-cli` | `latest` is v4, with download URLs on `downloads.sentry-cdn.com`. | `apps/sentry-cli/3` | @@ -98,12 +98,35 @@ x64 or arm64, or Windows on x64 or arm64. There are no musl (Alpine) wheels; use Sentry, also installs a `sentry` command, so do not install both into one environment. +### Homebrew + +Install v4 by its full name, `getsentry/tools/sentry`, as in +[Installation](#installation). Homebrew 6 and later load a formula from +`getsentry/tools` only if you [trust](https://docs.brew.sh/Tap-Trust) it, and +trust doesn't follow a rename. Installing by the full name trusts the formula, +so there is no separate `brew trust` step. The old name doesn't get you v4: + +- `brew install getsentry/tools/sentry-cli` fails with "Refusing to load + formula getsentry/tools/sentry from untrusted tap getsentry/tools." +- An existing `sentry-cli` install stays on 3.8.2. `brew update` lists it under + "Deleted Installed Formulae", and `brew upgrade` skips it. + +To stay on v3, use the `sentry-cli` cask from Homebrew's own repository. It +installs 3.8.2 as `sentry-cli` on macOS and Linux, next to `sentry` if you have +both: + +```bash +brew uninstall sentry-cli # if v3 is installed from getsentry/tools +brew install --cask sentry-cli +``` + ### Docker The v4 image keeps the `getsentry/sentry-cli` name and the `/work` working directory, so `docker run --rm -v "$PWD:/work" getsentry/sentry-cli ` -keeps working once you update the [command names](#command-changes). v3 -releases stay available under their version tags. What changed: +keeps working once you update the [command names](#command-changes). `latest` +is v4. To stay on v3, use `getsentry/sentry-cli:3`, which follows the newest +3.x release, or a 3.x version tag. What changed: - The entrypoint runs `sentry` directly. The v3 entrypoint dropped a leading `sentry-cli` argument and ran `sh` when asked; v4 passes every argument to @@ -114,6 +137,36 @@ releases stay available under their version tags. What changed: - The binary is `/usr/local/bin/sentry`; there is no `sentry-cli`. The image includes `git`. +Copying the binary into your own image needs the new path. The v4 binary needs +glibc and `libatomic1`, so it doesn't run on Alpine: + +```dockerfile +# v3 +COPY --from=getsentry/sentry-cli:3 /bin/sentry-cli /usr/local/bin/sentry-cli + +# v4 +COPY --from=getsentry/sentry-cli /usr/local/bin/sentry /usr/local/bin/sentry +``` + +A GitLab CI job can't use the v4 image, because GitLab runs the job's script +with a shell. Pin `getsentry/sentry-cli:3`, or run v4 in an image that has one: + +```yaml +# v3 +upload-sourcemaps: + image: + name: getsentry/sentry-cli:3 + entrypoint: [""] + script: + - sentry-cli sourcemaps upload ./dist + +# v4 +upload-sourcemaps: + image: node:22 + script: + - npx --yes sentry@4 sourcemap upload ./dist +``` + See [Docker](../getting-started/#docker) for usage. ## The `sentry-cli` → `sentry` rename From 2fe95a0385b979c3944e8e27008cf776ef9f68d4 Mon Sep 17 00:00:00 2001 From: "sentry-junior[bot]" <264270552+sentry-junior[bot]@users.noreply.github.com> Date: Sat, 5 Dec 2026 04:55:09 +0000 Subject: [PATCH 2/2] docs(cli): Say what sentry-cli does after the v4 rename The v4 binary run as sentry-cli and the PyPI sentry-cli command print a rename notice with the v3 pins and exit 1 (getsentry/toolkit#2929). Co-Authored-By: BYK <126780+BYK@users.noreply.github.com> --- apps/cli-docs/src/content/docs/migrating-from-v3.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/apps/cli-docs/src/content/docs/migrating-from-v3.md b/apps/cli-docs/src/content/docs/migrating-from-v3.md index ddceb65ce..e7ef14d64 100644 --- a/apps/cli-docs/src/content/docs/migrating-from-v3.md +++ b/apps/cli-docs/src/content/docs/migrating-from-v3.md @@ -70,7 +70,11 @@ sentry auth status v4 is also published under the v3 names, so upgrading through the channel you already use gets you v4. Every channel installs a `sentry` command; none -installs `sentry-cli`. Pin the major version to stay on v3. +installs a `sentry-cli` that runs v4. Pin the major version to stay on v3. + +The v4 binary, when run as `sentry-cli`, and PyPI `sentry-cli`'s `sentry-cli` +command print that the command is now `sentry`, link this guide and the v3 +pins, and exit 1. They never run v4 commands. | v3 channel | What a v4 upgrade does | Stay on v3 | |------------|------------------------|------------|