Write table report progress messages to stderr#1236
Conversation
Vincent-Maladiere
left a comment
There was a problem hiding this comment.
Hello @priscilla-b, thank you for this PR, LGTM :)
Woops, actually, need to look at what is failing in the CI
Yeahh trying to figure that out @Vincent-Maladiere |
|
So the issue comes from doctest, which checks that examples in the docstring match their expected value. We configured pytest to run doctest at the beginning of the test suite: Lines 276 to 277 in 4cdd5d9 You can reproduce this error with: from skrub import TableReport
import doctest
doctest.run_docstring_examples(
TableReport,
globals(),
optionflags=doctest.NORMALIZE_WHITESPACE + doctest.ELLIPSIS
)And to fix it, you have to replace Let me know if this works for you :) |
Yes, I was able to reproduce it ! |
Vincent-Maladiere
left a comment
There was a problem hiding this comment.
Great! This time, LGTM
jeromedockes
left a comment
There was a problem hiding this comment.
Thanks a lot @priscilla-b ! super useful 🚀 . a couple of small adjustments and we can merge it!
There was a problem hiding this comment.
I think the second print to add a newline on line 103 should also go to stderr
There was a problem hiding this comment.
Got it, will work on that
| assert capsys.readouterr().out != "" | ||
|
|
||
|
|
||
| def test_write_to_stderr(df_module, capsys): |
There was a problem hiding this comment.
once all progress output goes to stderr I think you will need to change the test_verbosity_parameter above to replace out with err
There was a problem hiding this comment.
Alright, that makes sense
jeromedockes
left a comment
There was a problem hiding this comment.
LGTM 🎉 thanks a lot @priscilla-b 👍
Towards #1175