Skip to content

Commit 3f526bf

Browse files
Remove sourcemaps upload artifact bundle option (#3002)
### Description Removed the deprecated `--use-artifact-bundle` flag from the `sentry-cli sourcemaps upload` command and its corresponding `useArtifactBundle` option from the Node.js API. This flag was a no-op that only emitted a deprecation warning, and its removal simplifies the CLI and API by eliminating an unused and misleading option. ### Issues * resolves: #2352 * resolves: CLI-20 --- <a href="https://cursor.com/background-agent?bcId=bc-2137bde5-9602-436e-9260-e3a6e192ae9c"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/open-in-cursor-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/open-in-cursor-light.svg"><img alt="Open in Cursor" src="https://cursor.com/open-in-cursor.svg"></picture></a>&nbsp;<a href="https://cursor.com/agents?id=bc-2137bde5-9602-436e-9260-e3a6e192ae9c"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/open-in-web-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/open-in-web-light.svg"><img alt="Open in Web" src="https://cursor.com/open-in-web.svg"></picture></a> ___ Co-authored-by: Daniel Szoke <daniel.szoke@sentry.io>
1 parent 32c1e9e commit 3f526bf

File tree

4 files changed

+2
-31
lines changed

4 files changed

+2
-31
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ we should rename this section to "Unreleased" -->
2121
- `apiKey` option in the JavaScript API
2222
- Removed the `upload-proguard` subcommand's `--app-id`, `--version`, `--version-code`, `--android-manifest`, and `--platform` arguments ([#2876](https://github.com/getsentry/sentry-cli/pull/2876), [#2940](https://github.com/getsentry/sentry-cli/pull/2940), [#2948](https://github.com/getsentry/sentry-cli/pull/2948)). Users using these arguments should stop using them, as they are unnecessary. The information passed to these arguments is no longer visible in Sentry.
2323
- Removed the `--started` argument from the `sentry-cli releases finalize` command ([#2972](https://github.com/getsentry/sentry-cli/pull/2972)). This argument is a no-op, so any users using it should simply stop using it.
24+
- Removed the `--use-artifact-bundle` flag from `sentry-cli sourcemaps upload` ([#3002](https://github.com/getsentry/sentry-cli/pull/3002)). The flag was a no-op that only emitted a deprecation warning.
2425

2526
#### Node.js Wrapper Breakages
2627

@@ -29,6 +30,7 @@ The following changes only apply when using `sentry-cli` via the npm package [`@
2930
- The `SentryCli.execute` method's `live` parameter now only takes boolean values ([#2971](https://github.com/getsentry/sentry-cli/pull/2971)). Setting `live` to `true` now behaves like `'rejectOnError'` did previously, with a zero exit status resolving the returned promise with `"success (live mode)"` and a non-zero status rejecting the promise with an error message.
3031
- The `option` parameter to `Releases.uploadSourceMaps` no longer takes a `live` property ([#2971](https://github.com/getsentry/sentry-cli/pull/2971)). We now always execute the command with `live` set to `true`.
3132
- Removed the `apiKey` option from `SentryCliOptions` ([#2935](https://github.com/getsentry/sentry-cli/pull/2935)). If you are using `apiKey`, you need to generate and use an [Auth Token](https://docs.sentry.io/account/auth-tokens/) via the `authToken` option, instead.
33+
- Removed the `useArtifactBundle` option from `SentryCliUploadSourceMapsOptions` ([#3002](https://github.com/getsentry/sentry-cli/pull/3002)). This deprecated option was a no-op that users should simply stop passing.
3234
- Drop support for Node.js <18. The minimum required Node.js version is now 18.0.0 ([#2985](https://github.com/getsentry/sentry-cli/issues/2985)).
3335

3436
### Improvements

lib/releases/options/uploadSourcemaps.js

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,4 @@ module.exports = {
5555
param: '--ext',
5656
type: 'array',
5757
},
58-
useArtifactBundle: {
59-
param: '--use-artifact-bundle',
60-
type: 'boolean',
61-
},
6258
};

lib/types.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -137,14 +137,6 @@ export interface SentryCliUploadSourceMapsOptions {
137137
* Usually your build number.
138138
*/
139139
dist?: string;
140-
/**
141-
* Force use of new Artifact Bundles upload, that enables use of Debug ID for Source Maps discovery,
142-
* even when the Sentry server does not declare support for it.
143-
*
144-
* @deprecated This option is deprecated and will be removed in the next major version. Sentry CLI
145-
* should always respect what the server says it supports.
146-
*/
147-
useArtifactBundle?: boolean;
148140
}
149141

150142
/**

src/commands/sourcemaps/upload.rs

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
#![expect(clippy::unwrap_used, reason = "contains legacy code which uses unwrap")]
22

3-
use std::env;
43
use std::path::PathBuf;
54
use std::time::Duration;
65

@@ -223,17 +222,6 @@ pub fn make_command(command: Command) -> Command {
223222
uploaded.",
224223
),
225224
)
226-
.arg(
227-
Arg::new("use_artifact_bundle")
228-
.long("use-artifact-bundle")
229-
.action(ArgAction::SetTrue)
230-
.help(
231-
"[DEPRECATED] Force artifact bundles to be used for upload, even when not \
232-
supported by the server. This option has always only been intended for \
233-
internal use, and it is now officially deprecated.",
234-
)
235-
.hide(true),
236-
)
237225
// Legacy flag that has no effect, left hidden for backward compatibility
238226
.arg(
239227
Arg::new("rewrite")
@@ -431,13 +419,6 @@ pub fn execute(matches: &ArgMatches) -> Result<()> {
431419
let mut processor = SourceMapProcessor::new();
432420
let chunk_upload_options = api.authenticated()?.get_chunk_upload_options(&org)?;
433421

434-
if matches.get_flag("use_artifact_bundle")
435-
|| env::var("SENTRY_FORCE_ARTIFACT_BUNDLES").ok().as_deref() == Some("1")
436-
{
437-
log::warn!("The --use-artifact-bundle option and the SENTRY_FORCE_ARTIFACT_BUNDLES environment variable \
438-
are both deprecated, and both will be removed in the next major version.");
439-
}
440-
441422
if matches.contains_id("bundle") && matches.contains_id("bundle_sourcemap") {
442423
process_sources_from_bundle(matches, &mut processor)?;
443424
} else {

0 commit comments

Comments
 (0)