-
-
Notifications
You must be signed in to change notification settings - Fork 305
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
The logger of the plugins module is named "__name__" instead of __name__ resulting in log messages that are not traceable to their source.
Expected behavior
The typo (presumably) is corrected and the log messages show alembic.runtime.plugins instead of __name__.
To Reproduce
Please try to provide a Minimal, Complete, and Verifiable example, with the migration script and/or the SQLAlchemy tables or models involved.
See also Reporting Bugs on the website.
import logging
from alembic.runtime.plugins import Plugin
logging.basicConfig(level="INFO")
Plugin("hello world")Error
INFO:__name__:setup plugin hello world
Versions.
- OS: macOS 26.2
- Python: 3.14.2
- Alembic: 1.18.0
- SQLAlchemy: 2.0.45
- Database: -
- DBAPI: -
Additional context
Should be an easy fix:
alembic/alembic/runtime/plugins.py
Line 21 in 1a3041c
| log = logging.getLogger("__name__") |
-log = logging.getLogger("__name__")
+log = logging.getLogger(__name__)Have a nice day!
edsu
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working