[issue35726] QueueHandler formating affects other handlers

2019-01-22 Thread Vinay Sajip


Vinay Sajip  added the comment:


New changeset da6424e96ada72c15c91bddb0a411acf7119e10a by Vinay Sajip 
(Manjusaka) in branch 'master':
bpo-35726: Prevented QueueHandler formatting from affecting other handlers 
(GH-11537)
https://github.com/python/cpython/commit/da6424e96ada72c15c91bddb0a411acf7119e10a


--

___
Python tracker 

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



[issue35726] QueueHandler formating affects other handlers

2019-01-12 Thread Manjusaka


Change by Manjusaka :


--
pull_requests:  -11140

___
Python tracker 

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



[issue35726] QueueHandler formating affects other handlers

2019-01-12 Thread Manjusaka


Change by Manjusaka :


--
pull_requests:  -11141

___
Python tracker 

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



[issue35726] QueueHandler formating affects other handlers

2019-01-12 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

@vinay.sajip It's known issue discussed here 
https://github.com/python/bugs.python.org/issues/12

--
nosy: +xtreak

___
Python tracker 

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



[issue35726] QueueHandler formating affects other handlers

2019-01-12 Thread Vinay Sajip


Vinay Sajip  added the comment:

Any idea why the same PR appears three times in the PR list? Is it because for 
some reason you've added the issue link multiple times in the PR, when it's not 
needed?

--

___
Python tracker 

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



[issue35726] QueueHandler formating affects other handlers

2019-01-12 Thread Manjusaka


Manjusaka  added the comment:

I have already work on a PR for it

--
nosy: +Manjusaka

___
Python tracker 

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



[issue35726] QueueHandler formating affects other handlers

2019-01-12 Thread Manjusaka


Change by Manjusaka :


--
keywords: +patch, patch, patch
pull_requests: +11140, 11141, 11142
stage:  -> patch review

___
Python tracker 

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



[issue35726] QueueHandler formating affects other handlers

2019-01-12 Thread Manjusaka


Change by Manjusaka :


--
keywords: +patch, patch
pull_requests: +11140, 11141
stage:  -> patch review

___
Python tracker 

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



[issue35726] QueueHandler formating affects other handlers

2019-01-12 Thread Manjusaka


Change by Manjusaka :


--
keywords: +patch
pull_requests: +11140
stage:  -> patch review

___
Python tracker 

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



[issue35726] QueueHandler formating affects other handlers

2019-01-12 Thread Karthikeyan Singaravelan


Change by Karthikeyan Singaravelan :


--
nosy: +vinay.sajip

___
Python tracker 

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



[issue35726] QueueHandler formating affects other handlers

2019-01-12 Thread David Ruggles


New submission from David Ruggles :

ISSUE: if you add a formatter to QueueHandler any subsequently added handlers 
will get the formatting added to QueueHandler

CAUSE: as best as I can tell, the code here:
https://github.com/python/cpython/blob/d586ccb04f79863c819b212ec5b9d873964078e4/Lib/logging/handlers.py#L1380
is modifying the record object so when it get passed to the next handler here:
https://github.com/python/cpython/blob/d586ccb04f79863c819b212ec5b9d873964078e4/Lib/logging/__init__.py#L1656
it includes the formatting applied by the QueueHandler's formatter.

I worked around this issue by moving my formatter from the QueueHandler to the 
QueueListener

I've attached a simple example of the issue

NOTE: I marked this as Python 3.7 because that's what I'm using, but I looked 
at github and the code is in master so I assume this affects 3.8 too.

--
components: Library (Lib)
files: queuehandler_bug.py
messages: 333526
nosy: David Ruggles
priority: normal
severity: normal
status: open
title: QueueHandler formating affects other handlers
versions: Python 3.7
Added file: https://bugs.python.org/file48044/queuehandler_bug.py

___
Python tracker 

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