Skip to content

Commit 05e7fca

Browse files
committed
Update OpenSSL module and improve conda environment activation in update_weather.sh
1 parent 4978b9f commit 05e7fca

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

update_weather.sh

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,15 @@
1515
module load LibTIFF/4.6.0-GCCcore-13.3.0
1616
module load R/4.4.2-gfbf-2024a
1717
module load cURL/8.7.1-GCCcore-13.3.0
18-
module load openssl/1.1.1
18+
module load OpenSSL/3
1919
module load Miniconda3/24.7.1-0
2020

21-
# Activate conda environment
22-
conda activate mosquito-alert-monitor
21+
# Initialize and activate conda environment
22+
source ~/.bashrc # Ensure conda is initialized
23+
if ! conda activate mosquito-alert-monitor; then
24+
echo "WARNING: Failed to activate conda environment mosquito-alert-monitor"
25+
echo "Continuing with default environment..."
26+
fi
2327

2428
# Load SSH agent since this is no longer done by default on the cluster
2529
eval "$(ssh-agent -s)"
@@ -94,10 +98,8 @@ $STATUS_SCRIPT "$JOB_NAME" "running" $(($(date +%s) - START_TIME)) 50
9498
R CMD BATCH --no-save --no-restore code/get_latest_data.R logs/get_latest_data_$(date +%Y%m%d_%H%M%S).out
9599

96100
if [ $? -eq 0 ]; then
97-
$STATUS_SCRIPT "$JOB_NAME" "completed" $(($(date +%s) - START_TIME)) 100
101+
$STATUS_SCRIPT "weather-hourly" "completed" $(($(date +%s) - START_TIME)) 100
98102
else
99-
$STATUS_SCRIPT "$JOB_NAME" "failed" $(($(date +%s) - START_TIME)) 50
100-
fi
101103
$STATUS_SCRIPT "weather-hourly" "failed" $(($(date +%s) - START_TIME)) 50
102104
fi
103105

0 commit comments

Comments
 (0)