Skip to content

Commit 79e70b6

Browse files
author
Jiri Papousek
committed
fix: send Content-Type: application/json when calling inference service
1 parent ee18e92 commit 79e70b6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ccx_upgrades_data_eng/inference.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def get_inference_for_predictors(
2626
settings = get_settings()
2727

2828
inference_endpoint = f"{settings.inference_url}/upgrade-risks-prediction"
29-
inference_response = requests.get(inference_endpoint, data=risk_predictors.json(), timeout=5)
29+
inference_response = requests.get(inference_endpoint, json=risk_predictors.model_dump(), timeout=5)
3030

3131
if inference_response.status_code != 200:
3232
raise HTTPException(status_code=inference_response.status_code)

0 commit comments

Comments
 (0)