fix: Face processor now saves status and total_faces to face.json
This commit is contained in:
Executable
+59
@@ -0,0 +1,59 @@
|
||||
#!/bin/bash
|
||||
# Test File Status API with Timestamps
|
||||
|
||||
set -e
|
||||
|
||||
FILE_UUID="${1:-d1e18fa4994aae32d9a63852a80c5a2a}"
|
||||
API_KEY="${2:-muser_68600856036340bcafc01930eb4bd839_1774418104_97221b69}"
|
||||
|
||||
echo "=== File Status API - Timestamp Test ==="
|
||||
echo "UUID: $FILE_UUID"
|
||||
echo ""
|
||||
|
||||
# Get file status
|
||||
RESPONSE=$(curl -s "http://localhost:3002/api/v1/stats/file/$FILE_UUID?api_key=$API_KEY")
|
||||
|
||||
echo "$RESPONSE" | python3 << 'PYEOF'
|
||||
import sys, json
|
||||
|
||||
try:
|
||||
data = json.load(sys.stdin)
|
||||
|
||||
print("File Status:")
|
||||
print(f" Name: {data.get('file_name', 'N/A')}")
|
||||
print(f" Status: {data.get('status', 'N/A')}")
|
||||
print()
|
||||
|
||||
print("Timestamps:")
|
||||
created = data.get('created_at')
|
||||
updated = data.get('updated_at')
|
||||
completed = data.get('processing_completed_at')
|
||||
|
||||
if created:
|
||||
print(f" Created: {created}")
|
||||
else:
|
||||
print(" Created: (not available)")
|
||||
|
||||
if updated:
|
||||
print(f" Updated: {updated}")
|
||||
else:
|
||||
print(" Updated: (not available)")
|
||||
|
||||
if completed:
|
||||
print(f" Completed: {completed}")
|
||||
else:
|
||||
print(" Completed: (not available)")
|
||||
|
||||
print()
|
||||
|
||||
# Check if feature is working
|
||||
has_timestamps = any([created, updated, completed])
|
||||
if has_timestamps:
|
||||
print("✅ Timestamp feature is working")
|
||||
else:
|
||||
print("⚠️ No timestamps found (may need server restart)")
|
||||
|
||||
except Exception as e:
|
||||
print(f"❌ Error parsing response: {e}")
|
||||
sys.exit(1)
|
||||
PYEOF
|
||||
Reference in New Issue
Block a user