Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions .github/workflows/quantms-containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ on:
branches: ["main"]
paths:
- "diann-*/Dockerfile"
- "diann-*/**"
- "relink-*/Dockerfile"
- ".github/workflows/**"
release:
Expand Down Expand Up @@ -42,6 +43,7 @@ jobs:
if: github.event_name == 'push' || github.event_name == 'pull_request'
with:
filters: |
diann_2_3_2: [ 'diann-2.3.2/**', '.github/workflows/**' ]
diann_2_2_0: [ 'diann-2.2.0/**', '.github/workflows/**' ]
diann_2_1_0: [ 'diann-2.1.0/**', '.github/workflows/**' ]
diann_2_0: [ 'diann-2.0.2/**', '.github/workflows/**' ]
Expand All @@ -53,6 +55,7 @@ jobs:
id: set-matrix
env:
EVENT: ${{ github.event_name }}
CHG_232: ${{ steps.filter.outputs.diann_2_3_2 }}
CHG_220: ${{ steps.filter.outputs.diann_2_2_0 }}
CHG_210: ${{ steps.filter.outputs.diann_2_1_0 }}
CHG_20: ${{ steps.filter.outputs.diann_2_0 }}
Expand All @@ -61,7 +64,8 @@ jobs:
CHG_RLK: ${{ steps.filter.outputs.relink_1_0_0 }}
run: |
DIANN_ALL='[
{"context":"diann-2.2.0","tag":"ghcr.io/bigbio/diann:2.2.0","sif":"diann-sif:2.2.0","extra_tags":"ghcr.io/bigbio/diann:latest","chg":"CHG_220"},
{"context":"diann-2.3.2","tag":"ghcr.io/bigbio/diann:2.3.2","sif":"diann-sif:2.3.2","extra_tags":"ghcr.io/bigbio/diann:latest","chg":"CHG_232"},
{"context":"diann-2.2.0","tag":"ghcr.io/bigbio/diann:2.2.0","sif":"diann-sif:2.2.0","extra_tags":"","chg":"CHG_220"},
Comment on lines +67 to +68
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Action required

1. Workflow repushes latest tag 🐞 Bug ☼ Reliability

Because .github/workflows/** is treated as a change for diann_2_3_2 and DIA-NN 2.3.2 is tagged
with ghcr.io/bigbio/diann:latest, a workflow-only change on main can rebuild and push :latest
even when the diann-2.3.2 build context did not change.
Agent Prompt
### Issue description
Workflow-only changes (under `.github/workflows/**`) currently make `diann_2_3_2` appear “changed”, and since 2.3.2 carries the `ghcr.io/bigbio/diann:latest` extra tag, this can republish `:latest` even when the container context didn’t change.

### Issue Context
This makes `:latest` mutable due to CI config edits and can change image digests without any Dockerfile/context changes.

### Fix Focus Areas
- .github/workflows/quantms-containers.yml[41-52]
- .github/workflows/quantms-containers.yml[66-73]
- .github/workflows/quantms-containers.yml[82-94]

### Suggested change (one of)
1) Remove `.github/workflows/**` from the per-image `dorny/paths-filter` rules so only actual image-context changes trigger builds/pushes.
2) Add a separate `workflow_changed` filter and, when only workflow files changed, either:
   - build without pushing (`push: false`), or
   - exclude `extra_tags` (especially `:latest`) from the matrix for that run.
3) Gate publishing of `extra_tags` (e.g., `:latest`) to `release` events only.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

{"context":"diann-2.1.0","tag":"ghcr.io/bigbio/diann:2.1.0","sif":"diann-sif:2.1.0","extra_tags":"","chg":"CHG_210"},
{"context":"diann-2.0.2","tag":"ghcr.io/bigbio/diann:2.0.2","sif":"diann-sif:2.0.2","extra_tags":"","chg":"CHG_20"},
{"context":"diann-1.9.2","tag":"ghcr.io/bigbio/diann:1.9.2","sif":"diann-sif:1.9.2","extra_tags":"","chg":"CHG_192"},
Expand All @@ -75,9 +79,10 @@ jobs:
DIANN=$(echo "$DIANN_ALL" | jq -c '[.[] | del(.chg)]')
RELINK=$(echo "$RELINK_ALL" | jq -c '[.[] | del(.chg)]')
else
DIANN=$(echo "$DIANN_ALL" | jq -c --arg c220 "${CHG_220:-false}" --arg c210 "${CHG_210:-false}" \
DIANN=$(echo "$DIANN_ALL" | jq -c --arg c232 "${CHG_232:-false}" --arg c220 "${CHG_220:-false}" --arg c210 "${CHG_210:-false}" \
--arg c20 "${CHG_20:-false}" --arg c192 "${CHG_192:-false}" --arg c181 "${CHG_181:-false}" \
'[.[] | select(
(.chg == "CHG_232" and $c232 == "true") or
(.chg == "CHG_220" and $c220 == "true") or
(.chg == "CHG_210" and $c210 == "true") or
(.chg == "CHG_20" and $c20 == "true") or
Expand Down
Loading