@@ -83,55 +83,47 @@ jobs:
83
83
- uses : DeterminateSystems/determinate-nix-action@main
84
84
- uses : DeterminateSystems/flakehub-cache-action@main
85
85
- run : |
86
- nix build -L --keep-going \
87
- $(nix flake show --json \
88
- | jq -r '
89
- .hydraJobs.tests
90
- | with_entries(select(.value.type == "derivation"))
91
- | keys[]
92
- | ".#hydraJobs.tests." + .')
86
+ cmd() {
87
+ nix build -L --keep-going --timeout 300 \
88
+ $(nix flake show --json \
89
+ | jq -r '
90
+ .hydraJobs.tests
91
+ | with_entries(select(.value.type == "derivation"))
92
+ | keys[]
93
+ | ".#hydraJobs.tests." + .')
94
+ }
95
+
96
+ if ! cmd; then
97
+ echo "failed, retrying once ..."
98
+ printf "\n\n\n\n\n\n\n\n"
99
+ cmd
100
+ fi
93
101
94
102
flake_regressions :
95
103
if : |
96
104
(inputs.run_regression_tests && github.event_name == 'merge_group')
97
105
|| (
98
- github.event.pull_request.head.repo.full_name == 'DeterminateSystems/nix-src'
106
+ inputs.run_regression_tests
107
+ && github.event.pull_request.head.repo.full_name == 'DeterminateSystems/nix-src'
99
108
&& (
100
109
(github.event.action == 'labeled' && github.event.label.name == 'flake-regression-test')
101
110
|| (github.event.action != 'labeled' && contains(github.event.pull_request.labels.*.name, 'flake-regression-test'))
102
111
)
103
112
)
104
113
needs : build
105
114
runs-on : ${{ inputs.runner }}
106
- steps :
107
- - name : Checkout nix
108
- uses : actions/checkout@v4
109
- - name : Checkout flake-regressions
110
- uses : actions/checkout@v4
111
- with :
112
- repository : DeterminateSystems/flake-regressions
113
- path : flake-regressions
114
- - name : Checkout flake-regressions-data
115
- uses : actions/checkout@v4
116
- with :
117
- repository : DeterminateSystems/flake-regressions-data
118
- path : flake-regressions/tests
119
- - uses : DeterminateSystems/determinate-nix-action@main
120
- - uses : DeterminateSystems/flakehub-cache-action@main
121
- - run : nix build -L --out-link ./new-nix && PATH=$(pwd)/new-nix/bin:$PATH PARALLEL="-P 50%" flake-regressions/eval-all.sh
115
+ strategy :
116
+ matrix :
117
+ nix_config :
118
+ - " lazy-trees = true"
119
+ - " lazy-trees = false"
120
+ glob :
121
+ - " [0-d]*"
122
+ - " [e-l]*"
123
+ - " [m]*"
124
+ - " [n-r]*"
125
+ - " [s-z]*"
122
126
123
- flake_regressions_lazy :
124
- if : |
125
- (inputs.run_regression_tests && github.event_name == 'merge_group')
126
- || (
127
- github.event.pull_request.head.repo.full_name == 'DeterminateSystems/nix-src'
128
- && (
129
- (github.event.action == 'labeled' && github.event.label.name == 'flake-regression-test')
130
- || (github.event.action != 'labeled' && contains(github.event.pull_request.labels.*.name, 'flake-regression-test'))
131
- )
132
- )
133
- needs : build
134
- runs-on : ${{ inputs.runner }}
135
127
steps :
136
128
- name : Checkout nix
137
129
uses : actions/checkout@v4
@@ -147,7 +139,24 @@ jobs:
147
139
path : flake-regressions/tests
148
140
- uses : DeterminateSystems/determinate-nix-action@main
149
141
- uses : DeterminateSystems/flakehub-cache-action@main
150
- - run : nix build -L --out-link ./new-nix && PATH=$(pwd)/new-nix/bin:$PATH PARALLEL="-P 50%" NIX_CONFIG="lazy-trees = true" flake-regressions/eval-all.sh
142
+ - env :
143
+ PARALLEL : " -P 50%"
144
+ FLAKE_REGRESSION_GLOB : ${{ matrix.glob }}
145
+ NIX_CONFIG : ${{ matrix.nix_config }}
146
+ run : |
147
+ set -x
148
+ if [ ! -z "${NSC_CACHE_PATH:-}" ]; then
149
+ mkdir -p "${NSC_CACHE_PATH}/nix/xdg-cache"
150
+ export XDG_CACHE_HOME="${NSC_CACHE_PATH}/nix/xdg-cache"
151
+ fi
152
+ nix build -L --out-link ./new-nix
153
+ export PATH=$(pwd)/new-nix/bin:$PATH
154
+
155
+ if ! flake-regressions/eval-all.sh; then
156
+ echo "Some failed, trying again"
157
+ printf "\n\n\n\n\n\n\n\n"
158
+ flake-regressions/eval-all.sh
159
+ fi
151
160
152
161
manual :
153
162
if : github.event_name != 'merge_group'
@@ -190,7 +199,6 @@ jobs:
190
199
- vm_tests_smoke
191
200
- vm_tests_all
192
201
- flake_regressions
193
- - flake_regressions_lazy
194
202
- manual
195
203
if : ${{ always() }}
196
204
runs-on : ubuntu-latest
0 commit comments