Skip to content

Commit a8a2a45

Browse files
ktfdavidrohr
authored andcommitted
FST: measure the AO2D size portably
stat -c%s is GNU syntax; BSD stat, as on macOS, rejects it, so the ASYNC check read an empty size and failed with "AO2D file (AO2D.root) exists but is empty" on a 470 kB AO2D. wc -c works on both.
1 parent d5cdad2 commit a8a2a45

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎prodtests/full_system_test.sh‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -337,7 +337,7 @@ for STAGE in $STAGES; do
337337
# Check AOD production for ASYNC stage
338338
if [[ "$STAGE" = "ASYNC" ]]; then
339339
if [[ -f "AO2D.root" ]]; then
340-
aod_size=`stat -c%s AO2D.root`
340+
aod_size=$(wc -c < AO2D.root)
341341
if [[ $aod_size -gt 0 ]]; then
342342
echo "AO2D file produced: AO2D.root (size: ${aod_size} bytes)"
343343
echo "aod_size_${STAGE},${TAG} value=${aod_size}" >> ${METRICFILE}

0 commit comments

Comments
 (0)