2727
2828 strategy :
2929 matrix :
30- os : [ubuntu-20.04 ]
31- python : ["3.10 "]
30+ os : [ubuntu-latest ]
31+ python : ["3.12 "]
3232 fail-fast : false
3333
3434 steps :
@@ -37,15 +37,15 @@ jobs:
3737
3838 - name : Cache Node Posix
3939 if : runner.os != 'Windows' && !env.ACT
40- uses : actions/cache@v3
40+ uses : actions/cache@v4
4141 with :
4242 path : ~/.npm
4343 key : npm-${{ runner.os }}-${{ env.cache-name }}
4444
4545 - name : Cache Phantoms
4646 if : ${{ !env.ACT }}
4747 id : phantom-cache
48- uses : actions/cache@v3
48+ uses : actions/cache@v4
4949 env :
5050 cache-name : cache-phantoms
5151 with :
6767 brew install dcm2niix
6868 fi
6969
70+
71+ - name : Check dcm2niix is installed and on path
72+ if : runner.os != 'Windows'
73+ run :
74+ dcm2niix -h
75+
7076 - name : Install dcm2niix windows
7177 if : runner.os == 'Windows'
7278 run : |
@@ -81,23 +87,26 @@ jobs:
8187 cache-dependency-path : |
8288 pypet2bids/pyproject.toml
8389
90+ - name : Install UV
91+ run : curl -LsSf https://astral.sh/uv/install.sh | sh && echo "$HOME/.cargo/bin" >> $GITHUB_PATH
92+
8493 - name : Install Python Dependencies
8594 run : |
8695 cd pypet2bids
87- pip install .
96+ pip install -e .[dev]
8897
89- - name : Install Poetry Build Package
98+ - name : Install UV Build Package
9099 run : |
91- make installpoetry
100+ make installuv
92101 make buildpackage
93- make installpackage
102+ cd pypet2bids && uv pip install dist/pypet2bids-*.whl --system
94103 dcm2niix4pet -h
95104
96105 - name : Set Up Node
97- uses : actions/setup-node@v3
106+ uses : actions/setup-node@v4
98107
99108 - name : Install BIDS Validator
100- run : npm install -g bids-validator
109+ run : npm install -g bids-validator@1.14.6
101110
102111 - name : Collect Phantoms
103112 if : ${{ steps.cache-phantoms.outputs.cache-hit != 'true' }} && ${{ !env.ACT }}
@@ -130,11 +139,15 @@ jobs:
130139 bash python_conversions.sh
131140
132141 - name : SetupMatlab
133- if : ${{ matrix.os == 'ubuntu-20.04 ' }}
142+ if : ${{ matrix.os == 'ubuntu-latest ' }}
134143 uses : matlab-actions/setup-matlab@v1
144+ # note matlab-actions/setup-matlab@v2 breaks this script, don't update unless you're forced to
145+ # with:
146+ # release: 'R2023a'
147+ # cache: true
135148
136149 - name : Run Matlab Conversion Script on Phantoms
137- if : ${{ matrix.os == 'ubuntu-20.04 ' }}
150+ if : ${{ matrix.os == 'ubuntu-latest ' }}
138151 uses : matlab-actions/run-command@v1
139152 with :
140153 command : |
@@ -154,6 +167,13 @@ jobs:
154167 run : |
155168 bids-validator OpenNeuroPET-Phantoms/python
156169
170+ - name : Debug
171+ uses : mxschmitt/action-tmate@v3
172+ if : ${{ github.event_name == 'workflow_dispatch' && inputs.debug_enabled }}
173+ timeout-minutes : 15
174+ with :
175+ limit-access-to-actor : true
176+
157177 - name : Validate Matlab Conversion
158178 run : |
159179 bids-validator OpenNeuroPET-Phantoms/matlab
0 commit comments