Skip to content

Commit 973e9ad

Browse files
committed
Add wait_for_status for flaky test for sagemaker-serve
1 parent e706e57 commit 973e9ad

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

sagemaker-serve/tests/integ/test_huggingface_integration.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,11 @@ def build_and_deploy():
101101
core_endpoint = model_builder.deploy(endpoint_name=f"{ENDPOINT_NAME_PREFIX}-{unique_id}")
102102
logger.info(f"Endpoint Successfully Created: {core_endpoint.endpoint_name}")
103103

104+
# Wait for endpoint to be in service
105+
logger.info("Waiting for endpoint to be in service...")
106+
core_endpoint.wait_for_status(status="InService")
107+
logger.info("Endpoint is now in service")
108+
104109
return core_model, core_endpoint
105110

106111

0 commit comments

Comments
 (0)