Skip to content

Commit

Permalink
Update L0_logging to reflect error when trying to update log_file
Browse files Browse the repository at this point in the history
  • Loading branch information
yinggeh committed Apr 13, 2024
1 parent e10b70f commit 380dc9e
Showing 1 changed file with 7 additions and 20 deletions.
27 changes: 7 additions & 20 deletions qa/L0_logging/logging_endpoint_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -227,34 +227,21 @@ def test_grpc_update_settings(self):
triton_client = grpcclient.InferenceServerClient("localhost:8001")

log_settings_1 = {
"log_file": "log_file.log",
"log_info": True,
"log_warning": True,
"log_error": True,
"log_verbose_level": 0,
"log_format": "default",
}
expected_log_settings_1 = grpcclient.service_pb2.LogSettingsResponse()
json_format.Parse(
json.dumps(
{
"settings": {
"log_file": {"stringParam": ""},
"log_info": {"boolParam": True},
"log_warning": {"boolParam": True},
"log_error": {"boolParam": True},
"log_verbose_level": {"uint32Param": 0},
"log_format": {"stringParam": "default"},
}
}
),
expected_log_settings_1,
expected_log_settings_1 = (
"log file location can not be updated through network protocol"
)

self.assertEqual(
expected_log_settings_1,
triton_client.update_log_settings(settings=log_settings_1),
"Unexpected updated log settings",
)
with self.assertRaisesRegex(
InferenceServerException, expected_log_settings_1
) as e:
triton_client.update_log_settings(settings=log_settings_1)

log_settings_2 = {
"log_info": False,
Expand Down

0 comments on commit 380dc9e

Please sign in to comment.