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
Log file names generated by gtest-parallel are too long #57
Comments
Do you think this could be solved alongside #54? The proposed solution there is that we have Importantly: We need to save the log files to disk even when |
.. and I think the output can't go to |
yes, this one is closely related.
I don't understand this. What I was thinking about when
|
I think it would be fine if log was an in-ram file handle on the OS level, what we had performance issues with was: There's a possibly-related post here: https://stackoverflow.com/a/10889177 but in our use we found delays / buffering / whatever that would not only delay the runtime with a constant factor but also see occasional bumps resulting both in timeouts (looking like flaky tests) and runtimes not representative of the underlying test runtime. We should add as little as possible to test runtimes or we're essentially lying. :) |
Perhaps something like |
So, to summarize. If Does this look reasonable? |
Yep, sounds good. Yes, once the test has finished running we should remove the file, regardless of if we print the contents before or not. If there are any If you implement this change I can take care of documentation updates if you'd prefer. |
See pull request #59. And yes please update the documentation. You'll definitely come up with better wording. |
Disable saving of log files by default If --output_dir command line options is omitted then gtest-parallel does not save any log files at all. Temporary files used for logging in this case are removed immediately after test's exit. Logs for failing tests are still dumped to console.
I've been hit by this at least 2 times.
Evidently, on Windows, there is a restriction of MAX_PATH (260 characters) FS path length.
On encrypted partition in Ubuntu (using eCryptfs). See this comment. Since eCryptfs protects not only file's content but also file names then there is an approximate restriction of 140 characters file name length.
There probably other cases when gtest-parallel can fail writing log file due to file/path length restrictions.
Now I'm considering options for fixing these issues all at once:
Make writing log files configurable and if it's disabled then write everything to console. Drawback: this will clutter the output.
Restrict file/path length. It seems we discussed this previously. For example, use hash of test name as log file name. Drawback: difficult to find log files for each specific test.
Try to use system extensions for writing longer file names. While this can be done on Windows it will not work for eCryptfs or any other FS without such extensions.
Propose yours.
I'm in favor of option 1. Which option is acceptable for gtest-parallel?
The text was updated successfully, but these errors were encountered: