Fix excessive logging on P2P retry#8511
Conversation
Unit Test ResultsSee test report for an extended history of previous test failures. This is useful for diagnosing flaky tests. 27 files ±0 27 suites ±0 10h 15m 5s ⏱️ + 22m 15s For more details on these failures, see this check. Results for commit cb05f69. ± Comparison against base commit fcfa7bc. ♻️ This comment has been updated with latest results. |
|
Can't say I'm too happy about this. partials are neat to read and I'm sure that someone else will walk in on your code, look at it, think "this would be much more readable with a partial" and change it. Wouldn't it be better to truncate the repr of the function at ~200 characters? |
I'm not too happy about it either but it patches an immediate pain for now. This has a test attached to it, so if someone changes this, they will trigger the test.
I would like the former; it should also address #8465. However, I'm not sure yet how to best approach this and it's not that high of a high priority for me. Regarding the latter, I don't have strong preferences when it comes to this vs my solution. I went with mine because it's more isolated, and I'm not sure if there are any situations where a hard truncate would remove relevant information, but if you prefer that, we can also truncate it over in |
|
I'll merge this PR, and I've opened up #8529 for the truncation in |
This PR avoids logging the entire retried partial including the applied arguments.
Previously, retrying in P2P would log excessively on retry:
Partially addresses #8465
pre-commit run --all-files