Skip to content
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

Remove a printf from db_stress that's not useful info #6705

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 0 additions & 2 deletions db_stress_tool/db_stress_stat.h
Expand Up @@ -204,8 +204,6 @@ class Stats {
covered_by_range_deletions_);

fprintf(stdout, "%-12s: Got errors %ld times\n", "", errors_);
fprintf(stdout, "%-12s: Got expected errors %ld times\n", "",
verified_errors_);
fprintf(stdout, "%-12s: %ld CompactFiles() succeed\n", "",
num_compact_files_succeed_);
fprintf(stdout, "%-12s: %ld CompactFiles() did not succeed\n", "",
Expand Down
3 changes: 1 addition & 2 deletions tools/db_crashtest.py
Expand Up @@ -453,8 +453,7 @@ def whitebox_crash_main(args, unknown_args):

stdoutdata = stdoutdata.lower()
errorcount = (stdoutdata.count('error') -
stdoutdata.count('got errors 0 times') -
stdoutdata.count('got expected errors 0 times'))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the problem might actually be this line: if the errors are expected, we shouldn't expect the number to be zero, no? That is, we might consider keeping the message in db_stress_stat.h and simply remove the 0 times part from here so that any number of expected errors are ignored.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought of doing that initially, but I don't think that print tells us anything useful anyway.

stdoutdata.count('got errors 0 times'))
print("#times error occurred in output is " + str(errorcount) + "\n")

if (errorcount > 0):
Expand Down