Repository navigation
ci(scraps): Scope release tags and automate versioning - #126643
Merged
Merged
Conversation
natemoo-re
marked this pull request as ready for review
October 6, 2026 20:47
BYK
approved these changes
Oct 6, 2026
Co-authored-by: Burak Yigit Kaya <byk@sentry.io>
aldy505
added a commit
to aldy505/sentry-publish
that referenced
this pull request
Oct 16, 2026
BYK
pushed a commit
to getsentry/publish
that referenced
this pull request
Oct 16, 2026
This was referenced Oct 22, 2026
BYK
added a commit
to getsentry/craft
that referenced
this pull request
Oct 22, 2026
Workspace changelogs treat every file outside all workspaces as shared,
so it lands in every workspace's changelog. That breaks repos where an
application lives at the root next to independently released packages.
In getsentry/sentry, `@sentry/scraps@0.2.0` picked up 785 commits since
`scraps@0.1.0`; only 21 touched `static/packages/scraps`. The rest were
backend changes under `src/` and `tests/`.
This adds `changelog.unownedPaths`:
- `include` (default): current behavior.
- `exclude`: this workspace ignores files outside every workspace.
- `own`: this workspace claims them, and every other workspace ignores
them. Only one workspace may set `own`. Workspaces without their own
`changelog` block inherit the top-level one, so a top-level `own` that
reaches several workspaces is rejected.
```yaml
workspaces:
sentry:
changelog:
unownedPaths: own
static/packages/scraps:
changelog:
policy: auto
```
## First releases
A workspace's first release has no matching tag, so Craft read the whole
repository history. When sentry switched scraps from `scraps-v*` to
`scraps@*` tags, `craft prepare` ran through about 75k commits and
~1,500 GraphQL batches, and the run was cancelled after 34 minutes.
Now, when no previous tag exists and a workspace is selected, Craft
walks back through `.craft.yml` history to the commit that first defined
the workspace's key and starts there. If that commit has no parent,
Craft keeps the full history. Craft now logs how many commits it reads:
at info level when it found a starting commit, and as a warning when it
falls back to the full history. Pushing a tag with the workspace's
prefix still overrides this.
Against a sentry checkout at the 0.2.0 release base, a first release of
`static/packages/scraps` reads 1,152 commits starting at the commit that
added the workspace (getsentry/sentry#126643) and keeps 21 once `sentry`
owns unowned paths.
## Relation to #920
#920 handles `includePaths` when Craft runs without workspaces. This PR
only changes workspace mode, so the two don't overlap in behavior.
`exclude` is the workspace option that #920's open question describes.
Both PRs edit the top of `getChangesSince`, so whichever lands second
needs a small rebase.
<!-- junior-request-attribution:start -->
via **BYK**.
<!-- junior-request-attribution:end -->
<!-- junior-session-footer:start -->
<!-- junior-conversation-id:local%3Aweb%3A5fa09a4fbd66e4ebf0b123c1 -->
--
[View Junior Session in
Sentry](https://sentry.sentry.io/explore/conversations/local%3Aweb%3A5fa09a4fbd66e4ebf0b123c1/?project=4510944073809921)
<!-- junior-session-footer:end -->
Co-authored-by: sentry-junior[bot] <264270552+sentry-junior[bot]@users.noreply.github.com>
Co-authored-by: BYK <burak.kaya@sentry.io>
BYK
added a commit
that referenced
this pull request
Oct 22, 2026
Since the move to Craft release workspaces (#126643), Craft treats every pnpm workspace directory as owned by something other than the `sentry` workspace. That includes `static/app`, `static/gsApp`, `static/gsAdmin`, `api-docs` and `tests/js`. Commits that only touch those directories are dropped from the automatic `CHANGES` changelog. Between `scraps@0.1.0` and the scraps 0.2.0 release base, that's 451 of 1,232 commits. This lists those directories under `changelog.includePaths` for the `sentry` workspace. With this config, 1,227 of the 1,232 commits are kept. The 5 still excluded only touch `static/packages/scraps` or its lint plugin. `includePaths` has been supported since Craft 2.32.0, below our `minVersion` of 2.33.1. The scraps and icons changelogs still pick up backend commits, because files outside every workspace (`src/`, `tests/`, …) count as shared. getsentry/craft#921 adds `changelog.unownedPaths: own` so the `sentry` workspace can claim those files. Setting it here will be a follow-up once that ships in a Craft release. <!-- junior-request-attribution:start --> via **BYK**. <!-- junior-request-attribution:end --> <!-- junior-session-footer:start --> <!-- junior-conversation-id:local%3Aweb%3A5fa09a4fbd66e4ebf0b123c1 --> -- [View Junior Session in Sentry](https://sentry.sentry.io/explore/conversations/local%3Aweb%3A5fa09a4fbd66e4ebf0b123c1/?project=4510944073809921) <!-- junior-session-footer:end --> --------- Co-authored-by: sentry-junior[bot] <264270552+sentry-junior[bot]@users.noreply.github.com> Co-authored-by: BYK <burak.kaya@sentry.io>
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#125903 added craft-based releases for
@sentry/scrapsbut had a few problems..craft.ymlfilescraps-v<version>which isn't an accepted standard formatThis PR updates the release process to...
.craft.ymlfile with workspacesscraps@<version>tagsauto(while still accepting explicit versions)