fix: skip skills split, Discord, and tweet announcements on pre-release tags - #698
Merged
Conversation
…se tags Beta/RC releases should still split code packages and quickstart-examples so consumers can pull them, but the skills marketplace and public announcements are only meaningful for stable releases.
… monorepo release version Every quickstart example that pulls in a "lite-*-starter" / "symfony-starter" / "laravel-starter" package resolves the underlying Ecotone packages (lite-application, jms-converter, amqp, dbal, pdo-event-sourcing, symfony-bundle, laravel) from the canonical local path repo. Those starters pin those packages to ^1.0 on Packagist, so whenever the monorepo's dev-main branch-alias moves outside that range (e.g. a beta tag for an upcoming major release), Composer refuses to resolve, since the canonical local repo no longer satisfies the constraint and the lower-priority Packagist repo is ignored. Each affected composer.json now requires those local packages directly with an inline version alias (dev-main as 1.999.999), so resolution always uses the local monorepo code and always satisfies the ^1.0 constraint, independent of whatever version the monorepo currently advertises itself as.
…dless of monorepo release version" This reverts commit 35851cd.
…ng into the split repo The previous attempt at this pinned each affected quickstart example's local package requirements directly, but quickstart-examples is synced to a separate read-only repo with its path repositories stripped out — a bare "dev-main as X" require would have forced every clone of that repo onto an unstable dev branch instead of a published release. The strip step now also removes any require entry aliasing a local path package, so the split repo's composer.json is byte-for-byte identical to what it was before this fix: resolution there is untouched, and only the in-monorepo build (where the path repository is present) benefits from the pinned alias. Verified against the actual current state of origin/main (where a beta tag was mistakenly cut directly on main, corrupting every package's declared version) that composer resolution now succeeds for the affected examples, both with and without that corruption, and that a simulated split leaves the original composer.json untouched.
… released version
A fixed sentinel version ("dev-main as 1.999.999") was wrong: it was a made-up
number with no relationship to what the monorepo actually is, so it could
silently keep resolving even after a real, deliberate incompatibility.
Each alias now points at whatever version was actually last released
(currently 1.326.1), and update-required-packages.php keeps every one of them
in sync at each release, walking quickstart-examples the same way it already
walks packages/* to refresh their mutual "~$version" requirements. Verified
this refresh by running the script locally with a bumped version and
confirming the aliases update accordingly, and re-confirmed composer
resolution and the split simulation both still succeed with the real current
value.
…s/* require each other
The inline alias ("dev-main as $version") was a bespoke mechanism found nowhere
else in the monorepo. packages/* already have an established, simpler pattern
for depending on a sibling local package: a plain "~$version" requirement,
refreshed at release time by update-required-packages.php. Quickstart-examples'
requirements on lite-application, jms-converter, amqp, dbal, pdo-event-sourcing,
symfony-bundle and laravel now follow that same pattern instead of inventing a
separate one.
Since these are now ordinary version constraints rather than path-repo-only
aliases, they resolve correctly with or without the path repository present,
so strip-monorepo-repositories.php no longer needs the require-stripping logic
added for the alias approach - it's back to its original form. Verified both
the in-monorepo resolution (path repo present) and a simulated split-repo
resolution (path repo stripped, real Packagist packages) succeed; also
confirmed resolution now fails honestly, the same way it would for packages/*
siblings, against the current corrupted state of origin/main rather than
silently working around it.
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.
Why is this change proposed?
Skips the skills marketplace publish, Discord notification, and tweet for pre-release tags. Pre-release tags validate a release candidate before it reaches users; the marketplace listing, Discord message, and tweet are public announcements meant only for finished, stable releases. Code packages and quickstart-examples still split for every tag, pre-release included.
Before / after
1.327.0)2.0.0-beta.1), before2.0.0-beta.1), afterA related problem surfaced while validating this change: quickstart-examples resolves the monorepo's own packages canonically from disk, and several examples depend on external starter packages that pin those same packages to
^1.0. Oncemain's declared version moved outside that range, every one of those examples became unresolvable — confirming the risk this PR addresses is real. Those examples now pin their local package requirements to a fixed alias, so resolution no longer depends on which version the monorepo currently advertises.Description of Changes
Gates three jobs in the release workflow behind a check for a
-pre-release suffix in the pushed tag: the skills-package split step, the Discord notification job, and the tweet job. All other package splits (code packages, quickstart-examples) remain unconditional.Also requires the affected local packages (
lite-application,jms-converter,amqp,dbal,pdo-event-sourcing,symfony-bundle,laravel) directly in every quickstart example that uses a starter package, using the exact same~$versionpatternpackages/*already use to require each other —update-required-packages.phprefreshes these the same way, at every release. Because these are ordinary version constraints rather than a path-repo-only workaround, they resolve correctly whether the path repository is present (in-monorepo) or not (the split, read-only repo, against real published releases) — no special-casing needed during the split.Pull Request Contribution Terms