Skip to content

Commit 80c4414

Browse files
Merge pull request #35 from bytebase/a-branch-7
fix
2 parents a2bc80d + 64ce223 commit 80c4414

File tree

1 file changed

+2
-11
lines changed

1 file changed

+2
-11
lines changed

.github/workflows/bb-export.yml

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -76,17 +76,8 @@ jobs:
7676
return 1
7777
fi
7878
79-
# Validate JSON response
80-
if ! python3 << 'EOF'
81-
import sys, json
82-
try:
83-
with open(sys.argv[1], 'r') as f:
84-
json.load(f)
85-
except json.JSONDecodeError as e:
86-
print(f'Invalid JSON: {str(e)}', file=sys.stderr)
87-
sys.exit(1)
88-
EOF
89-
"$temp_file" 2>/dev/null; then
79+
# Validate JSON response using a simple Python command
80+
if ! python3 -c "import json; json.load(open('$temp_file'))" 2>/dev/null; then
9081
echo "Error: Invalid JSON response"
9182
rm "$temp_file"
9283
return 1

0 commit comments

Comments
 (0)