Removed debug loggings
This commit is contained in:
@@ -452,19 +452,9 @@ async def alpinebits_server_handshake(
|
||||
# Decompress if needed
|
||||
if is_compressed:
|
||||
try:
|
||||
logger.info(f"Raw compressed body (first 200 bytes): {body[:200]!r}")
|
||||
|
||||
|
||||
body = gzip.decompress(body)
|
||||
logger.info("Successfully decompressed gzip content")
|
||||
|
||||
# log request to file like in wix-form/test
|
||||
logs_dir = "logs"
|
||||
if not os.path.exists(logs_dir):
|
||||
os.makedirs(logs_dir, mode=0o755, exist_ok=True)
|
||||
log_filename = f"{logs_dir}/alpinebits_request_{datetime.now().strftime('%Y%m%d_%H%M%S')}.txt"
|
||||
with open(log_filename, "wb") as f:
|
||||
f.write(body)
|
||||
|
||||
|
||||
|
||||
except Exception as e:
|
||||
raise HTTPException(
|
||||
@@ -478,15 +468,6 @@ async def alpinebits_server_handshake(
|
||||
status_code=400,
|
||||
detail="ERROR: Content-Type must be multipart/form-data"
|
||||
)
|
||||
|
||||
logger.info(f"Request body length: {len(body)} bytes")
|
||||
# log body to file for debugging
|
||||
logs_dir = "logs"
|
||||
if not os.path.exists(logs_dir):
|
||||
os.makedirs(logs_dir, mode=0o755, exist_ok=True)
|
||||
log_filename = f"{logs_dir}/alpinebits_request_{datetime.now().strftime('%Y%m%d_%H%M%S')}.txt"
|
||||
with open(log_filename, "wb") as f:
|
||||
f.write(body)
|
||||
|
||||
# Parse multipart data
|
||||
if "multipart/form-data" in content_type:
|
||||
|
||||
Reference in New Issue
Block a user