Repository: vllm-project/vllm (language: python)

Issue:
[help wanted]: rename vllm/logging module to avoid shadowing builtin logging module 
### Anything you want to discuss about vllm.

see https://github.com/vllm-project/vllm/issues/2021#issuecomment-2463435586 for more details.

we'd better avoid having a module that can potentially shadow python's builtin module, so that error trace can be clear.

solution could be:

rename `vllm.logging` to `vllm.logging_utils`

### Before submitting a new issue...

- [X] Make sure you already searched for relevant issues, and asked the chatbot living at the bottom right corner of the [documentation page](https://docs.vllm.ai/en/latest/), which can answer lots of frequently asked questions.


Discussion / hints:

Fix patch:
diff --git a/pyproject.toml b/pyproject.toml
index bae8645502dea..db373a4b1dd02 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -68,7 +68,7 @@ files = [
     "vllm/entrypoints",
     "vllm/core",
     "vllm/inputs",
-    "vllm/logging",
+    "vllm/logging_utils",
     "vllm/multimodal",
     "vllm/platforms",
     "vllm/transformers_utils",
diff --git a/vllm/logger.py b/vllm/logger.py
index d6fcda02a0fb3..80b9fcc59272d 100644
--- a/vllm/logger.py
+++ b/vllm/logger.py
@@ -24,7 +24,7 @@
 DEFAULT_LOGGING_CONFIG = {
     "formatters": {
         "vllm": {
-            "class": "vllm.logging.NewLineFormatter",
+            "class": "vllm.logging_utils.NewLineFormatter",
             "datefmt": _DATE_FORMAT,
             "format": _FORMAT,
         },
diff --git a/vllm/logging/__init__.py b/vllm/logging/__init__.py
deleted file mode 100644
index b9aec380776f3..0000000000000
--- a/vllm/logging/__init__.py
+++ /dev/null
@@ -1,5 +0,0 @@
-from vllm.logging.formatter import NewLineFormatter
-
-__all__ = [
-    "NewLineFormatter",
-]
diff --git a/vllm/logging_utils/__init__.py b/vllm/logging_utils/__init__.py
new file mode 100644
index 0000000000000..576ccf78a8117
--- /dev/null
+++ b/vllm/logging_utils/__init__.py
@@ -0,0 +1,5 @@
+from vllm.logging_utils.formatter import NewLineFormatter
+
+__all__ = [
+    "NewLineFormatter",
+]
diff --git a/vllm/logging/formatter.py b/vllm/logging_utils/formatter.py
similarity index 100%
rename from vllm/logging/formatter.py
rename to vllm/logging_utils/formatter.py


Test patch:
diff --git a/tests/test_logger.py b/tests/test_logger.py
index a937b0812ed0c..e3749616d4203 100644
--- a/tests/test_logger.py
+++ b/tests/test_logger.py
@@ -13,7 +13,7 @@
 
 from vllm.logger import (_DATE_FORMAT, _FORMAT, _configure_vllm_root_logger,
                          enable_trace_function_call, init_logger)
-from vllm.logging import NewLineFormatter
+from vllm.logging_utils import NewLineFormatter
 
 
 def f1(x):