Skip to content

Commit 2208455

Browse files
sjarmakclaude
andcommitted
fix: guard grep -v in 16 test.sh verifiers against set -e exit
Under set -e, `grep -v '^$'` returns exit code 1 when there are no matches, killing the verifier script before the reward file is written. This caused verifier_parse_error in sg_only mode where ALL_CHANGED can be empty after clone-at-verify. Also fix curl-security-review-001 Dockerfile.sg_only clone manifest: wrong mirror name (sg-evals/curl/curl -> sg-evals/curl--09e25b9d). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent a77167c commit 2208455

File tree

16 files changed

+19
-19
lines changed
  • benchmarks
    • ccb_build
      • flipt-dep-refactor-001/tests
      • flipt-flagexists-refactor-001/tests
    • ccb_design
      • django-rate-limit-design-001/tests
      • flipt-protobuf-metadata-design-001/tests
    • ccb_fix
      • django-modelchoice-fk-fix-001/tests
      • flipt-eval-latency-fix-001/tests
    • ccb_secure
      • django-audit-trail-implement-001/tests
      • django-cross-team-boundary-001/tests
      • django-legacy-dep-vuln-001/tests
      • django-policy-enforcement-001/tests
      • django-repo-scoped-access-001/tests
      • django-role-based-access-001/tests
      • django-sensitive-file-exclusion-001/tests
      • flipt-degraded-context-fix-001/tests
      • flipt-repo-scoped-access-001/tests
    • ccb_test/curl-security-review-001/environment

16 files changed

+19
-19
lines changed

benchmarks/ccb_build/flipt-dep-refactor-001/tests/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ ALL_CHANGED="$ALL_CHANGED
111111
$(git diff --name-only 2>/dev/null)
112112
$(git diff --cached --name-only 2>/dev/null)
113113
$(git ls-files --others --exclude-standard 2>/dev/null)"
114-
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$')
114+
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$' || true)
115115

116116
OUTSIDE_SCOPE=0
117117
if [ -n "$ALL_CHANGED" ]; then

benchmarks/ccb_build/flipt-flagexists-refactor-001/tests/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ ALL_CHANGED="$ALL_CHANGED
120120
$(git diff --name-only 2>/dev/null)
121121
$(git diff --cached --name-only 2>/dev/null)
122122
$(git ls-files --others --exclude-standard 2>/dev/null)"
123-
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$')
123+
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$' || true)
124124

125125
OUTSIDE_SCOPE=0
126126
if [ -n "$ALL_CHANGED" ]; then

benchmarks/ccb_design/django-rate-limit-design-001/tests/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ ALL_CHANGED="$ALL_CHANGED
130130
$(git diff --name-only 2>/dev/null)
131131
$(git diff --cached --name-only 2>/dev/null)
132132
$(git ls-files --others --exclude-standard 2>/dev/null)"
133-
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$')
133+
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$' || true)
134134

135135
OUTSIDE_SCOPE=0
136136
if [ -n "$ALL_CHANGED" ]; then

benchmarks/ccb_design/flipt-protobuf-metadata-design-001/tests/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ ALL_CHANGED="$ALL_CHANGED
144144
$(git diff --name-only 2>/dev/null)
145145
$(git diff --cached --name-only 2>/dev/null)
146146
$(git ls-files --others --exclude-standard 2>/dev/null)"
147-
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$')
147+
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$' || true)
148148

149149
OUTSIDE_SCOPE=0
150150
if [ -n "$ALL_CHANGED" ]; then

benchmarks/ccb_fix/django-modelchoice-fk-fix-001/tests/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ ALL_CHANGED="$ALL_CHANGED
8787
$(git diff --name-only 2>/dev/null)
8888
$(git diff --cached --name-only 2>/dev/null)
8989
$(git ls-files --others --exclude-standard 2>/dev/null)"
90-
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$')
90+
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$' || true)
9191

9292
OUTSIDE_SCOPE=0
9393
if [ -n "$ALL_CHANGED" ]; then

benchmarks/ccb_fix/flipt-eval-latency-fix-001/tests/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ ALL_CHANGED="$ALL_CHANGED
118118
$(git diff --name-only 2>/dev/null)
119119
$(git diff --cached --name-only 2>/dev/null)
120120
$(git ls-files --others --exclude-standard 2>/dev/null)"
121-
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$')
121+
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$' || true)
122122

123123
OUTSIDE_SCOPE=0
124124
if [ -n "$ALL_CHANGED" ]; then

benchmarks/ccb_secure/django-audit-trail-implement-001/tests/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ ALL_CHANGED="$ALL_CHANGED
8686
$(git diff --name-only 2>/dev/null)
8787
$(git diff --cached --name-only 2>/dev/null)
8888
$(git ls-files --others --exclude-standard 2>/dev/null)"
89-
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$')
89+
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$' || true)
9090

9191
OUTSIDE_SCOPE=0
9292
if [ -n "$ALL_CHANGED" ]; then

benchmarks/ccb_secure/django-cross-team-boundary-001/tests/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ ALL_CHANGED="$ALL_CHANGED
7474
$(git diff --name-only 2>/dev/null)
7575
$(git diff --cached --name-only 2>/dev/null)
7676
$(git ls-files --others --exclude-standard 2>/dev/null)"
77-
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$')
77+
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$' || true)
7878

7979
OUTSIDE_SESSIONS=0
8080
if [ -n "$ALL_CHANGED" ]; then

benchmarks/ccb_secure/django-legacy-dep-vuln-001/tests/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ ALL_CHANGED="$ALL_CHANGED
122122
$(git diff --name-only 2>/dev/null)
123123
$(git diff --cached --name-only 2>/dev/null)
124124
$(git ls-files --others --exclude-standard 2>/dev/null)"
125-
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$')
125+
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$' || true)
126126

127127
OUTSIDE_SCOPE=0
128128
if [ -n "$ALL_CHANGED" ]; then

benchmarks/ccb_secure/django-policy-enforcement-001/tests/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ fi
3131
# Get diff of new code
3232
DIFF=$(git diff HEAD~1..HEAD -- django/db/models/ 2>/dev/null || git diff -- django/db/models/ 2>/dev/null)
3333
ALL_CHANGED=$(git diff --name-only 2>/dev/null; git diff --cached --name-only 2>/dev/null; git ls-files --others --exclude-standard 2>/dev/null)
34-
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$')
34+
ALL_CHANGED=$(echo "$ALL_CHANGED" | sort -u | grep -v '^$' || true)
3535

3636
FUNC_SCORE=0
3737
POLICY_SCORE=0

0 commit comments

Comments
 (0)