2929 METRICS_ENDPOINT : ${{ secrets.METRICS_ENDPOINT }}
3030
3131jobs :
32- # ------------------------------------------ Check Files Changes ------------------------------------------
32+ prepare-environment :
33+ uses : ./.github/workflows/define-versions.yml
34+ # ------------------------------------------ Check Files Changes ------------------------------------------
3335 files-changed :
3436 name : Detect which file has changed
3537 runs-on : ubuntu-latest
@@ -154,7 +156,7 @@ jobs:
154156 !contains(needs.*.result, 'failure') &&
155157 !contains(needs.*.result, 'cancelled') &&
156158 (needs.files-changed.outputs.python == 'true') || (needs.files-changed.outputs.documentation_generated == 'true')
157- needs : ["files-changed", "yaml-lint", "python-lint"]
159+ needs : ["prepare-environment", " files-changed", "yaml-lint", "python-lint"]
158160 runs-on : " ubuntu-22.04"
159161 timeout-minutes : 5
160162 steps :
@@ -168,7 +170,7 @@ jobs:
168170 python-version : " 3.12"
169171 - name : " Setup Python environment"
170172 run : |
171- pipx install poetry==2.1
173+ pipx install poetry==${{ needs.prepare-environment.outputs.POETRY_VERSION }}
172174 poetry config virtualenvs.create true --local
173175 poetry env use 3.12
174176 - name : " Install dependencies"
@@ -220,7 +222,7 @@ jobs:
220222 !contains(needs.*.result, 'failure') &&
221223 !contains(needs.*.result, 'cancelled') &&
222224 needs.files-changed.outputs.python == 'true'
223- needs : ["files-changed", "yaml-lint", "python-lint"]
225+ needs : ["prepare-environment", " files-changed", "yaml-lint", "python-lint"]
224226 runs-on : ubuntu-latest
225227 timeout-minutes : 30
226228 steps :
@@ -232,7 +234,7 @@ jobs:
232234 python-version : ${{ matrix.python-version }}
233235 - name : " Setup environment"
234236 run : |
235- pipx install poetry==2.1 --python python${{ matrix.python-version }}
237+ pipx install poetry==${{ needs.prepare-environment.outputs.POETRY_VERSION }} --python python${{ matrix.python-version }}
236238 poetry config virtualenvs.create true --local
237239 pip install invoke toml codecov
238240 - name : " Install Package"
@@ -268,7 +270,7 @@ jobs:
268270 !contains(needs.*.result, 'failure') &&
269271 !contains(needs.*.result, 'cancelled') &&
270272 needs.files-changed.outputs.python == 'true'
271- needs : ["files-changed", "yaml-lint", "python-lint"]
273+ needs : ["prepare-environment", " files-changed", "yaml-lint", "python-lint"]
272274 runs-on :
273275 group : " huge-runners"
274276 timeout-minutes : 30
@@ -285,7 +287,7 @@ jobs:
285287 echo "PYTEST_DEBUG_TEMPROOT=/var/lib/github/${RUNNER_NAME}/_temp" >> $GITHUB_ENV
286288 - name : " Setup environment"
287289 run : |
288- pipx install poetry==2.1
290+ pipx install poetry==${{ needs.prepare-environment.outputs.POETRY_VERSION }}
289291 poetry config virtualenvs.create true --local
290292 pip install invoke toml codecov
291293 - name : " Install Package"
@@ -308,7 +310,7 @@ jobs:
308310 # !contains(needs.*.result, 'cancelled') &&
309311 # needs.files-changed.outputs.python == 'true' &&
310312 # (github.base_ref == 'stable' || github.base_ref == 'develop')
311- # needs: ["files-changed", "yaml-lint", "python-lint"]
313+ # needs: ["prepare-environment", " files-changed", "yaml-lint", "python-lint"]
312314 # runs-on:
313315 # group: "huge-runners"
314316 # timeout-minutes: 30
@@ -358,7 +360,7 @@ jobs:
358360
359361 # - name: "Setup environment"
360362 # run: |
361- # pipx install poetry==2.1
363+ # pipx install poetry==${{ needs.prepare-environment.outputs.POETRY_VERSION }}
362364 # poetry config virtualenvs.create true --local
363365 # pip install invoke toml codecov
364366
0 commit comments