[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-17 Thread Mariusz Felisiak


Change by Mariusz Felisiak :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-17 Thread Fred Drake


Fred Drake  added the comment:


New changeset 9bdb5802361016704fb3434369741cc6c5e08f02 by Mariusz Felisiak in 
branch '3.8':
bpo-43353: Document that logging.getLevelName() accepts string representation 
of logging level. (GH-24693) (#24825)
https://github.com/python/cpython/commit/9bdb5802361016704fb3434369741cc6c5e08f02


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-12 Thread miss-islington


miss-islington  added the comment:


New changeset 4d7f11e05731f67fd2c07ec2972c6cb9861d52be by Mariusz Felisiak in 
branch '3.9':
[3.9] bpo-43353: Document that logging.getLevelName() accepts string 
representation of logging level. (GH-24693) (GH-24826)
https://github.com/python/cpython/commit/4d7f11e05731f67fd2c07ec2972c6cb9861d52be


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-11 Thread Mariusz Felisiak


Mariusz Felisiak  added the comment:

I've prepared PRs with backports.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-11 Thread Mariusz Felisiak


Change by Mariusz Felisiak :


--
pull_requests: +23591
pull_request: https://github.com/python/cpython/pull/24826

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-11 Thread Mariusz Felisiak


Change by Mariusz Felisiak :


--
pull_requests: +23590
pull_request: https://github.com/python/cpython/pull/24825

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-10 Thread Fred Drake


Fred Drake  added the comment:

Mariusz: Good point.  IMO, an insane API behavior, but a legacy we must live 
with.

No further objections from me.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-10 Thread Mariusz Felisiak


Mariusz Felisiak  added the comment:

"numeric" doesn't refer to the "Level #" representation but to the fact that 
`getLevelName()` returns a numeric value when the corresponding name is passed, 
e.g.

>>> getLevelName('CRITICAL') 
50

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-10 Thread Fred Drake


Fred Drake  added the comment:

Just noticed this fly by in the stream of emails... sorry for not commenting 
earlier.

The patch seems to describe "Level #" as "numeric", which I would not be 
inclined to do.  It includes the numeric value since there's no available name 
for it, but as a value, it's still textual.

I'm referring specifically to the change here:
https://github.com/python/cpython/commit/bbba28212ce0f58096a4043f32442c6e727b74fc#diff-1bf0ad6d121df3948853dafdd8e5406709fe0c3911b30e3cf2def41717455c98R121

Otherwise, I do believe this should be back-ported.

--
nosy: +fdrake

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-10 Thread Mariusz Felisiak


Mariusz Felisiak  added the comment:

Do we want to backport this patch? If yes, I can prepare backports. If not, we 
can close the ticket.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-08 Thread miss-islington


miss-islington  added the comment:


New changeset bbba28212ce0f58096a4043f32442c6e727b74fc by Mariusz Felisiak in 
branch 'master':
bpo-43353: Document that logging.getLevelName() accepts string representation 
of logging level. (GH-24693)
https://github.com/python/cpython/commit/bbba28212ce0f58096a4043f32442c6e727b74fc


--
nosy: +miss-islington

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-01 Thread Vinay Sajip


Vinay Sajip  added the comment:

Sure, I'll look at a PR that mentions the other usage above the "changed in 
3.4" section.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43353] Document that logging.getLevelName() can return a numeric value.

2021-03-01 Thread Mariusz Felisiak


New submission from Mariusz Felisiak :

Can we document[1] that `logging.getLevelName()` returns a numeric value when 
corresponding string is passed in (related with 
https://bugs.python.org/issue1008295). I know that we have "Changed in version 
3.4" annotation but I think it's worth mentioning in the main description.

I hope it's not a duplicate, I tried to find matching ticket. 

I can submit PR if accepted.

[1] 
https://docs.python.org/3.10/library/logging.html?highlight=getlevelname#logging.getLevelName

--
components: Library (Lib)
messages: 387856
nosy: felixxm, vinay.sajip
priority: normal
severity: normal
status: open
title: Document that logging.getLevelName() can return a numeric value.

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com