Skip to content

Commit

Permalink
Add back cli arg
Browse files Browse the repository at this point in the history
Signed-off-by: JonahSussman <[email protected]>
  • Loading branch information
JonahSussman committed Jan 7, 2025
1 parent 9b3f41d commit 59c0863
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
7 changes: 7 additions & 0 deletions kai/rpc_server/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,13 @@

def add_arguments(parser: argparse.ArgumentParser) -> None:
parser.description = "Kai RPC Server"
parser.add_argument(
"-c",
"--config",
help="This parameter is deprecated and should not be used.",
type=str,
)

parser.add_argument(
"--log-level",
help="The initial log level for the server",
Expand Down
6 changes: 3 additions & 3 deletions tests/test_logging.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def test_logger_has_default(self) -> None:

self.assertEqual(log.getEffectiveLevel(), logging.NOTSET)
self.assertTrue(isinstance(log, KaiLogger))
self.assertEqual(log.configLogLevel, logging.NOTSET)
self.assertEqual(log.config_log_level, logging.NOTSET)
self.assertEqual(base_logger.filters, log.filters)
self.assertEqual(base_logger.handlers, log.handlers)

Expand Down Expand Up @@ -65,11 +65,11 @@ def test_logger_init_updates_logs(self) -> None:

self.assertTrue(isinstance(test_first_log, KaiLogger))
self.assertEqual(test_first_log.level, logging.NOTSET)
self.assertEqual(test_first_log.configLogLevel, base_logger.level)
self.assertEqual(test_first_log.config_log_level, base_logger.level)
self.assertEqual(len(test_first_log.filters), 0)
self.assertEqual(len(test_first_log.handlers), 0)
self.assertTrue(isinstance(test_second_log, KaiLogger))
self.assertEqual(test_second_log.level, logging.NOTSET)
self.assertEqual(test_second_log.configLogLevel, base_logger.level)
self.assertEqual(test_second_log.config_log_level, base_logger.level)
self.assertEqual(len(test_second_log.filters), 0)
self.assertEqual(len(test_second_log.handlers), 0)

0 comments on commit 59c0863

Please sign in to comment.