diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 9f6862151..ded678001 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -57,14 +57,14 @@ jobs: FILES=$(echo '${{ steps.filter.outputs.parsers_files }}' | jq -r '.[]') # Extract unique parser directories from both src and tests - SRC_PARSERS=$(echo "$FILES" | grep '^src/allotropy/parsers/' | cut -d'/' -f4 | grep -v '^utils$' | grep -v '^__pycache__$') - TEST_PARSERS=$(echo "$FILES" | grep '^tests/parsers/' | cut -d'/' -f3 | grep -v '^__pycache__$') + SRC_PARSERS=$(echo "$FILES" | grep '^src/allotropy/parsers/' | cut -d'/' -f4 | grep -v '^utils$' | grep -v '^__pycache__$' || true) + TEST_PARSERS=$(echo "$FILES" | grep '^tests/parsers/' | cut -d'/' -f3 | grep -v '^__pycache__$' || true) # Combine and get unique parsers - ALL_PARSERS=$(echo -e "$SRC_PARSERS\n$TEST_PARSERS" | sort -u | grep -v '^$') + ALL_PARSERS=$(echo -e "$SRC_PARSERS\n$TEST_PARSERS" | sort -u | grep -v '^$' || true) # Count unique parsers - PARSER_COUNT=$(echo "$ALL_PARSERS" | grep -v '^$' | wc -l) + PARSER_COUNT=$(echo "$ALL_PARSERS" | grep -v '^$' | wc -l || echo "0") if [[ $PARSER_COUNT -eq 1 ]]; then PARSER=$(echo "$ALL_PARSERS" | head -n1) diff --git a/src/allotropy/parsers/thermo_skanit/thermo_skanit_structure.py b/src/allotropy/parsers/thermo_skanit/thermo_skanit_structure.py index da2fc6e04..01f6dbfc9 100644 --- a/src/allotropy/parsers/thermo_skanit/thermo_skanit_structure.py +++ b/src/allotropy/parsers/thermo_skanit/thermo_skanit_structure.py @@ -321,6 +321,7 @@ def create( plate_well_counts: dict[str, int] = {} for plate in plates: + plate_well_count = 0 # Initialize to 0 in case no valid data is found for wavelength, data_df in plate.wavelength_data.items(): if data_df.empty: continue