Conversation
Codecov Report
@@ Coverage Diff @@
## devel #1155 +/- ##
==========================================
+ Coverage 89.32% 89.80% +0.48%
==========================================
Files 25 26 +1
Lines 1658 1707 +49
Branches 275 283 +8
==========================================
+ Hits 1481 1533 +52
+ Misses 131 128 -3
Partials 46 46 |
72b8be1 to
c24dab3
Compare
casperdcl
left a comment
There was a problem hiding this comment.
this is great. Perhaps should be in tqdm.contrib.logging or even just tqdm.contrib.__init__ for now?
https://github.com/tqdm/tqdm/#redirecting-writing still uses tqdm.contrib for the stdout/err redirection.
I moved it to |
7742d89 to
4125dcc
Compare
added logging sub-module python 2 compatibility fixed python 2 fix added test for custom tqdm class python 2 absolute imports (due to otherwise conflicting `logging` module) isort more tests relating to _get_first_found_console_formatter isort minor simplification test handleError test logging formatter being used minor rename to _get_first_found_console_logging_formatter test that certain exceptions are not swallowed avoid using mock.assert_called (py 3.5) moved to tqdm.contrib.logging added "Redirecting console logging to tqdm" readme removed no longer necessary absolute_import declaration minor: updated package of example in docstring
4125dcc to
7458666
Compare
|
fixes #786 |
|
Hah @cthoyt it's a well overdue implementation of #786 - just never had enough free time to action it sooner; sorry. Full credit to @de-code though for one of the cleanest code PRs I've seen on this site.
It may look like I modded a lot but most of that was documentation, not code. |
this implements a slightly improved version of #786
The solution mainly differs from the one outlined in #786 in the following ways:
loggerscan be specified (still optional, and probably not needed most of the time)tqdmclass can be passed in