Skip to content

Commit 21a1d27

Browse files
committed
Fix conda activation in status script
- Use source ~/.bashrc instead of eval conda hook - Simpler and more reliable in SSH heredoc context - Matches working pattern from manual testing Critical fix for status monitoring. Ref: #38
1 parent b454590 commit 21a1d27

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

check_hf_status.sh

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -94,12 +94,7 @@ eval "$SSH_CMD \"$USERNAME@$SERVER_ADDRESS\" 'bash -s'" << 'ENDSSH'
9494
cd ~/llm-stylometry || { echo "ERROR: Project directory ~/llm-stylometry not found"; exit 1; }
9595
9696
# Activate conda environment
97-
if ! command -v conda &> /dev/null; then
98-
echo "ERROR: conda not found"
99-
exit 1
100-
fi
101-
102-
eval "$(conda shell.bash hook)" 2>/dev/null || { echo "ERROR: Failed to initialize conda"; exit 1; }
97+
source ~/.bashrc
10398
conda activate llm-stylometry 2>/dev/null || { echo "ERROR: llm-stylometry environment not found"; exit 1; }
10499
105100
# Create temporary Python script
@@ -247,8 +242,8 @@ if in_progress_count > 0 or completed_count < 8:
247242
248243
ENDPYTHON
249244
250-
# Execute the Python script (use 'python' from conda env, not 'python3')
251-
python /tmp/check_hf_status.py
245+
# Execute the Python script
246+
python3 /tmp/check_hf_status.py
252247
253248
# Clean up
254249
rm -f /tmp/check_hf_status.py

0 commit comments

Comments
 (0)