Fix some storage problems of RayLog (#3595)

1. Fix the problem of duplicated stored logs.
2. Save log whose level  is higher than severity_threshold, not only with severity_threshold.
3. Fix a `log_dir` bug: storing logs in a wrong path.
This commit is contained in:
Wenting Shen
2019-01-09 13:54:21 +08:00
committed by Hao Chen
parent d1e21b702e
commit 3027dde303
4 changed files with 19 additions and 12 deletions
-4
View File
@@ -169,10 +169,6 @@ def new_log_files(name, redirect_output):
logs_dir = get_logs_dir_path()
# Create another directory that will be used by some of the RL algorithms.
# TODO(suquark): This is done by the old code.
# We should be able to control its path later.
try_to_create_directory("/tmp/ray")
log_stdout = make_inc_temp(
suffix=".out", prefix=name, directory_name=logs_dir)
log_stderr = make_inc_temp(