This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author andrei.avk
Recipients andrei.avk, andylowry, eric.smith, shreyanavigyan, vinay.sajip
Date 2021-05-17.21:22:42
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1621286562.3.0.384510916778.issue43858@roundup.psfhosted.org>
In-reply-to
Content
I can add getLevelNamesDict() which would return a copy of _nameToLevel, which is currently

_nameToLevel = {
    'CRITICAL': CRITICAL,
    'FATAL': FATAL,
    'ERROR': ERROR,
    'WARN': WARNING,
    'WARNING': WARNING,
    'INFO': INFO,
    'DEBUG': DEBUG,
    'NOTSET': NOTSET,
}

I think it may be best not to return a list of levels because it's not obvious that some of them are aliases, if the caller is responsible for making the list out of the dict, they will be able to decide how to deal with alias levels.

If that sounds good I can make a PR..
History
Date User Action Args
2021-05-17 21:22:42andrei.avksetrecipients: + andrei.avk, vinay.sajip, eric.smith, shreyanavigyan, andylowry
2021-05-17 21:22:42andrei.avksetmessageid: <1621286562.3.0.384510916778.issue43858@roundup.psfhosted.org>
2021-05-17 21:22:42andrei.avklinkissue43858 messages
2021-05-17 21:22:42andrei.avkcreate