ci: add release branch compatibility check to PR validation#2550
ci: add release branch compatibility check to PR validation#2550
Conversation
|
Azure Pipelines: 1 pipeline(s) require an authorized user to comment /azp run to run. |
|
Hey @smamindl 👋! We use semantic commit messages to streamline the release process. Examples of commit messages with semantic prefixes:
To test your commit locally, please follow our guild on building from source. |
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.Scanned FilesNone |
|
/azp run |
|
Azure Pipelines: Successfully started running 1 pipeline(s). |
There was a problem hiding this comment.
Pull request overview
Adds a new Azure DevOps PR-validation job to check whether release branches (starting with spark4.0) can be cleanly replayed onto incoming PR changes and still build, aiming to catch release-branch breakage before merging to master.
Changes:
- Adds a
ReleaseBranchCompatjob that fetches a release branch and attempts to rebase its unique commits onto the PR HEAD. - Runs
sbt compile test:compileafter the rebase. - Adds additional setup and unit-test execution steps for multiple packages, and publishes test results.
| FAILURES=0 | ||
| for pkg in core automl causal featurize image isolationforest stages recommendation nn train vw opencv exploratory; do | ||
| echo "=== Testing $pkg ===" | ||
| if ! timeout 10m sbt $(SBT_JAVA_OPTS) "testOnly com.microsoft.azure.synapse.ml.$pkg.**"; then | ||
| echo "##vso[task.logissue type=warning]$pkg tests failed on $(RELEASE_BRANCH)" | ||
| FAILURES=$((FAILURES + 1)) | ||
| fi | ||
| done | ||
| if [ $FAILURES -gt 0 ]; then | ||
| echo "##vso[task.logissue type=warning]$FAILURES package(s) failed on $(RELEASE_BRANCH)" |
There was a problem hiding this comment.
The unit-test loop invokes sbt once per package, which repeatedly pays sbt startup/resolve costs and increases the chance of hitting the 30/60 minute timeouts. Consider running tests in fewer sbt invocations (e.g., a single sbt session with multiple testOnly commands) or using the existing UnitTests matrix approach instead of a loop.
| FAILURES=0 | |
| for pkg in core automl causal featurize image isolationforest stages recommendation nn train vw opencv exploratory; do | |
| echo "=== Testing $pkg ===" | |
| if ! timeout 10m sbt $(SBT_JAVA_OPTS) "testOnly com.microsoft.azure.synapse.ml.$pkg.**"; then | |
| echo "##vso[task.logissue type=warning]$pkg tests failed on $(RELEASE_BRANCH)" | |
| FAILURES=$((FAILURES + 1)) | |
| fi | |
| done | |
| if [ $FAILURES -gt 0 ]; then | |
| echo "##vso[task.logissue type=warning]$FAILURES package(s) failed on $(RELEASE_BRANCH)" | |
| PACKAGES=(core automl causal featurize image isolationforest stages recommendation nn train vw opencv exploratory) | |
| SBT_COMMANDS=() | |
| for pkg in "${PACKAGES[@]}"; do | |
| echo "=== Queueing tests for $pkg ===" | |
| SBT_COMMANDS+=("testOnly com.microsoft.azure.synapse.ml.$pkg.**") | |
| done | |
| if ! timeout 25m sbt $(SBT_JAVA_OPTS) "${SBT_COMMANDS[@]}"; then | |
| echo "##vso[task.logissue type=warning]Unit tests failed on $(RELEASE_BRANCH)" |
0e2b1bb to
1408fa0
Compare
Add a ReleaseBranchCompat job that runs on every PR to master. It rebases each release branch (starting with spark4.0) onto the PR HEAD and runs sbt compile test:compile to catch breakage before it lands in master. - Non-blocking (continueOnError: true) - Matrix-based for easy expansion to more release branches - Reports merge conflicts and compile failures as warnings Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1408fa0 to
00832d1
Compare
Adds a ReleaseBranchCompat job to the ADO pipeline that catches release branch breakage at PR time, before changes land in master.
What it does
On every PR to master, for each release branch (starting with spark4.0):
recommendation, nn, train, vw, opencv, exploratory)
If rebase conflicts or compile/tests fail, the PR author sees a warning while they're still in context.
Design decisions
Related Issues/PRs
#xxx
What changes are proposed in this pull request?
Briefly describe the changes included in this Pull Request.
How is this patch tested?
CI validated on builds 215268893 (all steps passed) and 215256519.
Does this PR change any dependencies?
Does this PR add a new feature? If so, have you added samples on website?
website/docs/documentationfolder.Make sure you choose the correct class
estimators/transformersand namespace.DocTablepoints to correct API link.yarn run startto make sure the website renders correctly.<!--pytest-codeblocks:cont-->before each python code blocks to enable auto-tests for python samples.WebsiteSamplesTestsjob pass in the pipeline.