Implemented TFLogSinks#41733
Conversation
- added a `no_default_logger` config setting - changed `TFLogEntry::log_severity()` to `TFLogEntry::Severity()` - changed `TFLogEntry::ToString()` to `TFLogEntry::Message()` - added `TFLogEntry::FName()` and `TFLogEntry::Line()` - added TFDefaultLogSink - TFAddLogSink and TFRemoveLogSink now work
|
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed (or fixed any issues), please reply here with What to do if you already signed the CLAIndividual signers
Corporate signers
ℹ️ Googlers: Go here for more info. |
|
@googlebot I signed it! |
|
CLAs look good, thanks! ℹ️ Googlers: Go here for more info. |
|
Rohan, adding you because it looks like you expressed interest in reviewing in the attached issue. But please comment if that's changed. Rohan is currently out, so I wouldn't expect an immediate response. |
|
@rohan100jain Any update on this PR? Please. Thanks! |
1 similar comment
|
@rohan100jain Any update on this PR? Please. Thanks! |
|
@rohan100jain Any update on this PR? Please. Thanks! |
|
Come on y'all. This has been pending since July. Any updates? |
|
Look, I know this is not the most sophisticated logging scheme: this will work just the same for what it already did and allow users to actually redirect TF logging. It is not an asynchronous logging system, so adding multiple sinks will degrade performance. However, this implements the interface that existed in TF for years and lied about it being implemented the whole time. If you have any questions about whether the code is valid, I'll certainly answer them, but I don't understand why this is taking so long to approve and why so many people want to look at it before merging. Sure, it adds critical functionality to TF, but this is textbook stuff, not exactly rocket science. At the end of the day, it doesn't change the existing behavior one bit, and it's a starting point for someone to make this a better logging system in the future if you ever decide to dedicate resources to this. This is one of many patches I already have to apply to our TensorFlow build, please make this one less. P.S. We actually back this by a proper, high performance logger, as I think most users would. A logging hook like this is absolutely critical for any big library. |
|
I too am interested in seeing this make it into tensorflow. This has been needed for a while. |
|
Alright, I see the CI now! Sorry about the broken build: I was merging this from a patch to 1.15.4, must have made a mistake with that. Will fix today. |
|
@kkimdev, sorry, I didn't notice your other comment, so I made two checkins instead of one. I think you'll need to re-kick the CI. |
|
@kkimdev , all your comments have been addressed. It should all be there now... |
|
@gbaned I don't see the corresponding CL internally, is this because it didn't pass all the Kokoro tests? |
|
Update: getting internal reviews now, we should be able to land after getting one more lgtm internally! :) |
|
@avitebskiy I had to update quite a bit to be consistent with internal logger behavior and just removed linux tests that didn't work internally for some reason, but the functionality should be merged and available now. In case if you have a follow-up changes, please keep it coming. Thanks! |
no_default_loggerconfig settingTFLogEntry::log_severity()toTFLogEntry::Severity()TFLogEntry::ToString()toTFLogEntry::Message()TFLogEntry::FName()andTFLogEntry::Line()TFDefaultLogSinkTFAddLogSinkandTFRemoveLogSinknow work