fix: correct indentation error in Python debugging script
All checks were successful
audit / audit (push) Has been skipped
ci-cd / build (push) Has been skipped
ci / build (push) Has been skipped
autofix / fix (push) Has been skipped
security-scanning / audit (push) Has been skipped
test / test (push) Has been skipped
ci-cd / deploy (push) Has been skipped
ci / deploy (push) Has been skipped
All checks were successful
audit / audit (push) Has been skipped
ci-cd / build (push) Has been skipped
ci / build (push) Has been skipped
autofix / fix (push) Has been skipped
security-scanning / audit (push) Has been skipped
test / test (push) Has been skipped
ci-cd / deploy (push) Has been skipped
ci / deploy (push) Has been skipped
INDENTATION FIX: Resolve Python syntax error in import debugging Issue: - IndentationError: unexpected indent in Python debugging script - Caused workflow to fail with exit status 1 - Blocked test execution entirely Fix: - Corrected Python script indentation - Moved import sys to top level - Proper try/except block structure - Clean f-string formatting Expected results: - No more IndentationError - Import debugging should work - Test execution should proceed - Clear feedback on import success/failure This should allow the workflow to continue past the debugging section and actually run the pytest tests.
This commit is contained in:
@@ -129,23 +129,23 @@ jobs:
|
|||||||
# Test specific imports that are failing
|
# Test specific imports that are failing
|
||||||
echo "Testing problematic imports..."
|
echo "Testing problematic imports..."
|
||||||
venv/bin/python -c "
|
venv/bin/python -c "
|
||||||
try:
|
import sys
|
||||||
import sys
|
print('Testing src import...')
|
||||||
print('Testing src import...')
|
sys.path.insert(0, '/opt/gitea-runner/workspace/repo/apps/agent-protocols/src')
|
||||||
sys.path.insert(0, '/opt/gitea-runner/workspace/repo/apps/agent-protocols/src')
|
try:
|
||||||
import message_protocol
|
import message_protocol
|
||||||
print('✅ src.message_protocol import successful')
|
print('✅ src.message_protocol import successful')
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
print(f'❌ src import failed: {e}')
|
print(f'❌ src import failed: {e}')
|
||||||
|
|
||||||
try:
|
print('Testing aitbc import...')
|
||||||
print('Testing aitbc import...')
|
sys.path.insert(0, '/opt/gitea-runner/workspace/repo/apps/blockchain-node/src')
|
||||||
sys.path.insert(0, '/opt/gitea-runner/workspace/repo/apps/blockchain-node/src')
|
try:
|
||||||
import aitbc_chain
|
import aitbc_chain
|
||||||
print('✅ aitbc_chain import successful')
|
print('✅ aitbc_chain import successful')
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
print(f'❌ aitbc import failed: {e}')
|
print(f'❌ aitbc import failed: {e}')
|
||||||
"
|
"
|
||||||
|
|
||||||
echo "=== RUNNING PYTHON TESTS ==="
|
echo "=== RUNNING PYTHON TESTS ==="
|
||||||
echo "Attempting to run tests with comprehensive error handling..."
|
echo "Attempting to run tests with comprehensive error handling..."
|
||||||
|
|||||||
Reference in New Issue
Block a user