DreamStream-1 commited on
Commit
3fd9853
·
verified ·
1 Parent(s): ce91e8f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -0
app.py CHANGED
@@ -904,6 +904,9 @@ def send_whatsjet_message(phone_number: str, message: str, media_type: str = Non
904
  response = requests.get(media_path, stream=True, timeout=15)
905
  response.raise_for_status()
906
  media_content = response.content
 
 
 
907
  else:
908
  # Read from local file
909
  with open(media_path, 'rb') as f:
 
904
  response = requests.get(media_path, stream=True, timeout=15)
905
  response.raise_for_status()
906
  media_content = response.content
907
+ # Log the first 20 bytes and content type
908
+ logger.info(f"[WhatsJet][DEBUG] Downloaded image content-type: {response.headers.get('Content-Type')}")
909
+ logger.info(f"[WhatsJet][DEBUG] First 20 bytes: {media_content[:20]}")
910
  else:
911
  # Read from local file
912
  with open(media_path, 'rb') as f: