From 38a98ed11a747f682874dbee3dd2d455c76a7376 Mon Sep 17 00:00:00 2001 From: mashehu Date: Wed, 29 Jul 2026 12:23:56 +0200 Subject: [PATCH 1/2] add nextflow version fallback to handle pipelines with strict and non-strict syntax in sync action --- .github/workflows/sync.yml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml index e62b7a4869..7d9cf05901 100644 --- a/.github/workflows/sync.yml +++ b/.github/workflows/sync.yml @@ -108,7 +108,31 @@ jobs: git config --global init.defaultBranch $defaultBranch - name: Run synchronisation + id: sync if: github.repository == 'nf-core/tools' + continue-on-error: true + env: + GITHUB_AUTH_TOKEN: ${{ secrets.nf_core_bot_auth_token }} + run: | + git config --global user.email "core@nf-co.re" + git config --global user.name "nf-core-bot" + uv run nf-core --log-file sync_log_${{ matrix.pipeline }}.txt \ + ${{ github.event.inputs.debug == 'true' && '--verbose' || '' }} \ + pipelines sync -d nf-core/${{ matrix.pipeline }} \ + --from-branch dev \ + --pull-request \ + --username nf-core-bot \ + --github-repository nf-core/${{ matrix.pipeline }} \ + --blog-post ${{inputs.blog_post}} + + - name: Install newer Nextflow (retry fallback) + if: github.repository == 'nf-core/tools' && steps.sync.outcome == 'failure' + uses: nf-core/setup-nextflow@893c28b667aedeba26e37f296d260ccc5bc4d914 # v3 + with: + version: "26.04.6" + + - name: Retry synchronisation with newer Nextflow + if: github.repository == 'nf-core/tools' && steps.sync.outcome == 'failure' env: GITHUB_AUTH_TOKEN: ${{ secrets.nf_core_bot_auth_token }} run: | From eb5028dfd174251b3dd08f513b1d317c73ec2090 Mon Sep 17 00:00:00 2001 From: mashehu Date: Wed, 29 Jul 2026 12:25:34 +0200 Subject: [PATCH 2/2] catch traceback if nextflow config command fails --- nf_core/utils.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/nf_core/utils.py b/nf_core/utils.py index e53744bb88..93a09971ba 100644 --- a/nf_core/utils.py +++ b/nf_core/utils.py @@ -553,7 +553,12 @@ def fetch_wf_config(wf_path: Path, cache_config: bool = True) -> dict: log.debug("No config cache found") # Call `nextflow config` - result = run_cmd("nextflow", f"config -o json {wf_path}") + try: + result = run_cmd("nextflow", f"config -o json {wf_path}") + except RuntimeError as e: + raise UserWarning( + f"Could not parse Nextflow config for '{wf_path}'. Possibly because of a Nextflow version mismatch?\n{e}" + ) from e if result is not None: nfconfig_raw, _ = result try: