-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Data] Restructure stdout logging #43360
Conversation
Signed-off-by: Cheng Su <scnju13@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rather than manually specifying log_to_stdout=False
, would it be difficult to configure the logger so that we don't print info and debug levels by default?
"Starting execution of Dataset. Monitor progress on Ray " | ||
"Dashboard." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel like the "Monitor progress on Ray Dashboard" part isn't helpful since you already receive a message when Ray initializes instructing you to view the dashboard.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was wanted to emphasize that people should use dashboard for monitoring. I can also remove this, WDYT? @raulchen.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed for now.
We need to make sure they are still logging to log file though, and not interfere w/ |
I think the easiest way would be to save both |
Signed-off-by: Cheng Su <scnju13@gmail.com>
Got it, @scottjlee, @bveeramani - how about leaving this as a followup? Two loggers sound complicated to me, and I want us to be able to clear up logging in 2.10. |
@@ -251,7 +259,7 @@ def _scheduling_loop_step(self, topology: Topology) -> bool: | |||
""" | |||
|
|||
if DEBUG_TRACE_SCHEDULING: | |||
logger.get_logger().info("Scheduling loop step...") | |||
logger.get_logger(log_to_stdout=False).info("Scheduling loop step...") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this one is already behind a debug flag. can keep log_to_stdout=True
for easier debugging
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make sense, changed.
Signed-off-by: Cheng Su <scnju13@gmail.com>
Hey @bveeramani, @c21, heads up that I found the default of:
Highly, highly annoying. I probably wasted 1.5 hours trying to figure out how to turn it off. There's |
@moinnadeem sorry to hear that. That sounds super frustrating.
Looks like this is a bug. Created an Issue to track: #44267.
Would you mind telling me more? Are you getting spammy behavior where the progress bar doesn't render properly, or is something else? |
The bar spams so much that looking for my print statements is like looking for a needle in a haystack. Things are fine now that I disabled it, but I think printing as much as you do isn't a sane default. For reference, I probably have 100 Ray outputs for every output in my program! I'm on Slack if you want to chat more, we can set up a time where I can show you this (it contains some sensitive stuff, so can't post on GitHub) |
@moinnadeem I fixed an issue and now the progress bars are supposed to adjust width automatically (so it won't keep printing new lines). One exceptional case is when your python script is launched by a shell script, this will be broken. Does your case happen to be the same? |
This is a followup of #43360 to fix the behavior of disabling progress bar. After this PR, users only need to set `ray.data.DataContext.get_current().enable_progress_bars = False` to disable all progress bar (main + verbose bar per operator). Tested locally and verified config is working. Signed-off-by: Cheng Su <scnju13@gmail.com>
This is a followup of ray-project#43360 to fix the behavior of disabling progress bar. After this PR, users only need to set `ray.data.DataContext.get_current().enable_progress_bars = False` to disable all progress bar (main + verbose bar per operator). Tested locally and verified config is working. Signed-off-by: Cheng Su <scnju13@gmail.com>
This is a followup of ray-project#43360 to fix the behavior of disabling progress bar. After this PR, users only need to set `ray.data.DataContext.get_current().enable_progress_bars = False` to disable all progress bar (main + verbose bar per operator). Tested locally and verified config is working. Signed-off-by: Cheng Su <scnju13@gmail.com>
Why are these changes needed?
This PR is to restructure the standard output logging of Ray Data w/ motivation to provide useful information for users, because we heard from multiple users that the logging on standard output is spammy and not that useful.
The change includes:
info
/debug
-level log on stdout. Thewarn
/error
-level log is still on stdout. All logs are persisted inray-data.log
file.ray-data.log
file and physical execution plan.The stdout after this PR:
The stdout before this PR:
Related issue number
Checks
git commit -s
) in this PR.scripts/format.sh
to lint the changes in this PR.method in Tune, I've added it in
doc/source/tune/api/
under thecorresponding
.rst
file.