Migrate to new Nextflow plugin build system (#323) - #324
Conversation
Removes the legacy buildSrc/launch.sh/plugins/build.gradle structure and
adopts the io.nextflow.nextflow-plugin Gradle plugin (1.0.0-beta.6) per
the Seqera migration guide.
What changed:
- Delete buildSrc/, launch.sh, plugins/build.gradle, plugins/nf-quilt/build.gradle,
groovysh helpers, plugins/nf-quilt/src/resources/META-INF/{MANIFEST.MF,extensions.idx}
- Move plugin sources from plugins/nf-quilt/src/{main,test,resources} to
src/main/groovy, src/test/groovy, src/main/resources (standard layout
expected by the new plugin)
- Replace settings.gradle with single rootProject.name line
- New root build.gradle declaring quiltcore, jackson-databind,
jackson-datatype-jsr310, commons-io as runtime deps; nextflowPlugin {}
block declares className, provider, extensionPoints (QuiltObserverFactory,
QuiltPathFactory, QuiltPathSerializer); inline plugin version 0.9.2
- Rewrite Makefile around assemble / installPlugin / releasePlugin while
preserving pkg-test / dyn-test / s3-* targets (now invoke `nextflow`
directly instead of launch.sh, install plugin via gradle first)
- Update .github/workflows/test.yml artifact paths to build/reports
- QuiltSpecification + QuiltPkgTest read MANIFEST.MF from build/tmp/jar/
(where the new gradle plugin generates it during the jar task), with
legacy paths kept as fallbacks
- Test task gets --add-opens jvmArgs and dependsOn jar so the manifest
exists before tests start
- Clear gradle.properties (legacy keys no longer needed)
Plugin-Version is unchanged (0.9.2). The 1.0.0 release happens in a
later PR.
Refs #323
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
🦙 MegaLinter status: ✅ SUCCESS
See detailed report in MegaLinter reports |
| update: | ||
| ./gradlew useLatestVersions | ||
| make check | ||
| ./gradlew dependencyUpdates |
There was a problem hiding this comment.
dependencyUpdates task not available in the new build
./gradlew dependencyUpdates is provided by the com.github.ben-manes.versions plugin, which was removed from the new build.gradle. Running make update will fail with "Task 'dependencyUpdates' not found". The old Makefile used useLatestVersions (from se.patrikerdes.use-latest-versions), also now absent. If dependency-update checking is still desired, the corresponding plugin should be re-added to build.gradle.
There was a problem hiding this comment.
Fixed in ef33379 — removed the update Makefile target. Will reintroduce alongside a versions-plugin replacement if/when needed.
The io.nextflow.nextflow-plugin gradle plugin wires `test` to depend on
`assemble` (which transitively triggers `packagePlugin`). On Windows,
`packagePlugin` fails with "character to be escaped is missing" because
upstream uses `String.replaceAll('\\.', File.separator)` and `\` is the
escape character in regex replacements. Filed upstream as
nextflow-io/nextflow-plugin-gradle#20.
Until that's fixed:
- Sever the test->assemble dependency so `./gradlew test` (and therefore
`make test` in CI) runs on Windows. `make assemble`, `make package`,
and `make release` still pull in `packagePlugin` on platforms where it
works.
- Bump to 1.0.0-beta.14 (latest) — same Windows bug, but worth being on
the most recent release otherwise.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Remove broken Makefile targets (coverage, update) that referenced the removed jacoco and com.github.ben-manes.versions plugins - Add missing -plugins flag to s3-test target - Use withInputStream so the manifest FileInputStream is closed deterministically Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
## Summary PR 2 of the 4-PR migration to the Nextflow Plugin Registry (#323). PR 1 was the structural rewrite (#324). This PR is documentation + restoring the JaCoCo coverage gate; no version bump and no source/test changes. - **Docs:** Replace legacy build/publish references (`launch.sh`, `make publish`, `nextflow-io/plugins` PR flow, `NXF_PLUGINS_TEST_REPOSITORY` GitHub-release pinning, `plugins/` subproject, `buildSrc`) in `README-DEV.md` with the new `io.nextflow.nextflow-plugin` workflow: `make assemble`/`install`/`package`/`release` and `./gradlew releasePlugin` (requires `NPR_API_KEY`) for publishing to registry.nextflow.io. `README.md` did not contain stale references and was left as-is. - **Changelog:** Added bullets to the in-flight `[0.9.2] 2026-04-29` section noting the registry migration, the new build system, dropped `nextflow-io/plugins` flow, doc updates, and JaCoCo restoration. No new version section (1.0.0 entry comes in the release PR). - **JaCoCo:** Re-added `id 'jacoco'` to the plugins block, configured `jacocoTestReport` and `jacocoTestCoverageVerification` (70% line minimum, mirroring the pre-migration threshold), and wired `check` to depend on the verification task. Restored `coverage` / `verifyCoverage` Makefile targets and updated `.PHONY`. - **Verified locally** with JDK 21: `./gradlew check` passes including `jacocoTestCoverageVerification` at the 70% bar — no threshold reduction needed. Refs #323 ## Test plan - [x] `./gradlew check` passes locally with the 70% JaCoCo gate enabled - [ ] CI green on this branch - [ ] Manual review of doc changes for accuracy vs. the new build flow --------- Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
## Summary First release published to the [Nextflow Plugin Registry](https://registry.nextflow.io). Bumps the plugin version to `1.0.0`, consolidating the unpublished `0.9.2` intermediate into the registry-migration release. This is the final PR in the migration tracked by #323. It bundles three previously-merged PRs: - #322 — Jackson `OffsetDateTime` serialization fix for Nextflow 24.10+ - #324 — Migrate to the new `io.nextflow.nextflow-plugin` Gradle build system - #327 — Docs refresh + restore JaCoCo 70% line-coverage gate ## Changes - `build.gradle`: `version = '0.9.2'` -> `'1.0.0'` - `CHANGELOG.md`: rename `[0.9.2]` section to `[1.0.0]` and add note about Nextflow Plugin Registry as the publishing channel - `README-DEV.md`: bump example `nf-quilt@0.9.2` references to `@1.0.0` The `dest-1.0.0` test package has been pre-published to `s3://udp-spec` so `QuiltPkgTest > should confirm contents of dest URI` passes in CI. ## Post-merge manual steps (human) The actual registry publish is intentionally NOT automated in this PR: 1. `git tag 1.0.0 && git push origin 1.0.0` 2. `export NPR_API_KEY=... && ./gradlew releasePlugin` 3. Verify the plugin appears on https://registry.nextflow.io 4. Close #321 with the registry URL ## Test plan - [x] `./gradlew test` passes - [x] `./gradlew check` passes (JaCoCo gate satisfied) - [x] `./gradlew packagePlugin` produces `build/distributions/nf-quilt-1.0.0.zip` - [x] `make pkg-test WRITE_BUCKET=udp-spec` published `nf-quilt/dest-1.0.0` to `udp-spec` - [ ] CI green Closes #323 Closes #321 🤖 Generated with [Claude Code](https://claude.com/claude-code) <!-- greptile_comment --> <h3>Greptile Summary</h3> This PR bumps the plugin version from `0.9.2` to `1.0.0` across `build.gradle`, `CHANGELOG.md`, and `README-DEV.md` in preparation for the first publish to the Nextflow Plugin Registry. All `0.9.2` references have been consistently updated and no stale occurrences remain in the repository. <h3>Confidence Score: 4/5</h3> Safe to merge — changes are purely a version bump with no functional code modifications. Only P2 finding (stale comment in build.gradle); no logic, security, or correctness issues present. No files require special attention beyond the minor stale comment in build.gradle line 17. <h3>Important Files Changed</h3> | Filename | Overview | |----------|----------| | build.gradle | Version bumped from 0.9.2 to 1.0.0; stale "until the 1.0.0 release" comment left in place (P2) | | CHANGELOG.md | Section heading renamed from [0.9.2] to [1.0.0]; registry publication note prepended — no issues found | | README-DEV.md | Four nf-quilt version references updated from 0.9.2 to 1.0.0 in example commands — no issues found | </details> <h3>Flowchart</h3> ```mermaid %%{init: {'theme': 'neutral'}}%% flowchart TD A["build.gradle\nversion = '1.0.0'"] --> B["./gradlew packagePlugin\nnf-quilt-1.0.0.zip"] B --> C["git tag 1.0.0\ngit push origin 1.0.0"] C --> D["./gradlew releasePlugin\nNPR_API_KEY set"] D --> E["Nextflow Plugin Registry\nregistry.nextflow.io"] F["CHANGELOG.md\n1.0.0 section"] -.-> B G["README-DEV.md\nnf-quilt at 1.0.0"] -.-> E ``` <sub>Reviews (1): Last reviewed commit: ["Release 1.0.0"](c7e63de) | [Re-trigger Greptile](https://app.greptile.com/api/retrigger?id=30280267)</sub> > Greptile also left **1 inline comment** on this PR. <!-- /greptile_comment --> --------- Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

Summary
Migrates the build from the legacy
buildSrc/launch.sh/plugins/build.gradlelayout to the newio.nextflow.nextflow-pluginGradle plugin, per the Seqera migration guide. This combines PR steps 1+2 from the issue breakdown — they're interdependent (deleting the old build files without a replacement breaks CI), so they're shipped together.Refs #323.
What changed
buildSrc/,launch.sh,plugins/build.gradle,plugins/nf-quilt/build.gradle,groovysh-task.gradle,gradle-groovysh-init.gradle, and the now-redundantplugins/nf-quilt/src/resources/META-INF/{MANIFEST.MF,extensions.idx}(the Gradle plugin generates these).plugins/nf-quilt/src/main→src/main/groovyplugins/nf-quilt/src/test→src/test/groovyplugins/nf-quilt/src/resources→src/main/resourcessettings.gradlereduced torootProject.name = 'nf-quilt'.build.gradleappliesio.nextflow.nextflow-plugin1.0.0-beta.6, declaresquiltcore,jackson-databind,jackson-datatype-jsr310,commons-ioas runtime deps, and configuresnextflowPlugin {}withclassName = 'nextflow.quilt.QuiltPlugin', providerQuilt Data, and three extension points (QuiltObserverFactory,QuiltPathFactory,QuiltPathSerializer). Plugin version is inlined as0.9.2(unchanged).Makefilerewritten aroundassemble/installPlugin/releasePlugin. The legacypkg-test,dyn-test,s3-*integration targets are preserved but now usenextflowdirectly (thelaunch.shshim is gone) and depend oninstallPluginto seed~/.nextflow/plugins/..github/workflows/test.ymlartifact paths updated fromplugins/nf-quilt/build/reports/tobuild/reports/.QuiltSpecificationandQuiltPkgTestnow read the generatedMANIFEST.MFfrombuild/tmp/jar/(where the new plugin emits it), with the legacy paths kept as fallbacks. Thetesttask gets the standard--add-opensJVM args anddependsOn 'jar'so the manifest exists before tests run.gradle.propertiescleared (legacy Groovy/JDK toolchain keys are no longer needed — the Gradle plugin handles all of that).Deviations from the migration guide
QuiltSpecificationdoes a fullPlugins.initround-trip, which needsMANIFEST.MFon disk. Rather than rewrite all 200+ tests, I pointed theTestPluginDescriptorFinderat the generated manifest and addedtasks.named('test') { dependsOn 'jar' }.build.gradlerather than read from a now-deletedMANIFEST.MFsource file. This matches the migration guide's example.verifyCoveragetask is dropped frommake test. The new Gradle plugin doesn't apply JaCoCo, and reapplying it cleanly is out of scope. Worth a follow-up if we want the 70% gate back.Test plan
./gradlew assemble— succeeds (producesbuild/libs/nf-quilt-0.9.2-meta.json+nf-quilt-0.9.2.zip)./gradlew test— 226 tests, 222 passing, 14 skipped, 0 failing (locally on JDK 21)make test— greenmake pkg-test WRITE_BUCKET=udp-specagainst real S3 (out of scope for this PR; the existingnf-quilt/dest-0.9.2package onudp-specshould still satisfyQuiltPkgTest)Deferred to subsequent PRs
README.md,README-DEV.md,CHANGELOG.md. This PR only touches the build layer; references toplugins/nf-quilt/...paths in docs were left alone where they aren't actively broken.Plugin-Versionto1.0.0and the actual registry release.releasePluginagainst the registry (no--dry-runoption exists; needs an API key).Greptile Summary
This PR migrates the nf-quilt plugin build from the legacy
buildSrc/launch.sh/nested-build.gradlelayout to theio.nextflow.nextflow-pluginGradle plugin, moving sources to the standard flat layout the new plugin expects and updating the Makefile and CI artifact paths accordingly.logback-test.xmlinsrc/main/resources/: this file will be packaged into the production JAR and force<root level="DEBUG">logging for every user of the plugin; it must move tosrc/test/resources/.make coverageandmake updatetargets: thejacocoTestReportanddependencyUpdatesGradle tasks referenced by these targets no longer exist in the newbuild.gradle, causing both targets to fail.s3-testtarget missing-pluginsflag: unlike all other integration targets,s3-testdoes not pass-plugins $(PROJECT)@$(VERSION), so Nextflow will resolve from the registry instead of the locally installed build.Confidence Score: 3/5
Not safe to merge as-is: the logback-test.xml placement will pollute production logging for all plugin users, and two Makefile targets will fail at runtime.
Two P1s: (1) logback-test.xml in src/main/resources/ ships DEBUG root logging into the production JAR, and (2)
make coverageandmake updatereference Gradle tasks removed from the new build, causing hard failures. The core Gradle migration and source-move appear correct, but these issues must be fixed before merging.src/main/resources/logback-test.xml (wrong directory — must be src/test/resources/); Makefile (coverage and update targets broken, s3-test missing -plugins flag)
Important Files Changed
make coveragecalls a removed jacocoTestReport task,make updatecalls a removed dependencyUpdates task, ands3-testis missing the-pluginsflagFlowchart
%%{init: {'theme': 'neutral'}}%% flowchart TD A[./gradlew assemble] --> B[build/libs/nf-quilt-0.9.2.zip] A --> C[build/tmp/jar/MANIFEST.MF] C --> D[QuiltSpecification.setupSpec\nreads MANIFEST.MF] D --> E[Plugins.init / startIfMissing] E --> F[Test suite runs\n226 tests] G[make install] --> H[./gradlew installPlugin] H --> I[~/.nextflow/plugins/nf-quilt-0.9.2/] I --> J[nextflow run ... -plugins nf-quilt@0.9.2] K[make release] --> L[./gradlew releasePlugin] L --> M[Seqera Plugin Registry] style C fill:#f9f,stroke:#c0c style D fill:#f9f,stroke:#c0cComments Outside Diff (1)
src/main/resources/logback-test.xml, line 1-31 (link)logback-test.xmlbelongs insrc/test/resources/, notsrc/main/resources/. By living insrc/main/resources/it will be included in the production plugin ZIP/JAR. Logback resolveslogback-test.xmloverlogback.xml, so every Nextflow user who loads this plugin will inherit the<root level="DEBUG">configuration, flooding their console with debug output from all loggers at runtime.Reviews (1): Last reviewed commit: "Migrate to new Nextflow plugin build sys..." | Re-trigger Greptile