refactor: Revise Logger portability through modules#144
Open
refactor: Revise Logger portability through modules#144
Logger portability through modules#144Conversation
Collaborator
Author
|
I added a suggested pre-commit hook script. I find it easier to check that all linter and formatters pass. That the doc compiled too. If you think this deserves a PR on its own, I can adjust |
Contributor
RomainBaville
left a comment
There was a problem hiding this comment.
You have done a great job, it seems easier to maintain and limite the code duplication.
geos-processing/src/geos/processing/generic_processing_tools/FillPartialArrays.py
Show resolved
Hide resolved
Collaborator
|
Looks good to me ! |
jafranc
commented
Oct 3, 2025
Collaborator
Author
jafranc
left a comment
There was a problem hiding this comment.
Then I'll proceed changing other files 👍
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR aims at revising the
Loggerand logging portability between VTK filters and their paraview plugins counterparts (in geos-pv). It plans to:Extend under first round approval the decorator to all plugins--- New arch---
Based on
VTKHandlerexample,GEOSHandlerto have access toemitlogic and formatGEOSFomatterwith aTrimColorfuncion to help passing bash color tag free string to vtk inner logicgetLoggerbut withpropagate=Trueto stick to originalloggingclass train of thoughts and allow file handler too. Might be replace bylogging.getLoggersoon, if proper refactor and encapsulation of logger init is done.The addition does not need an "adding function" type of decorator, just to decorate the handler removal step in the PV plugin initializer. Then removal of previous
detailshelpers ingeos-utilsand appening toLoggermoduleThis will includes all PV plugins with exceptions:
PVGeosBlockExtractMerge.py,PVMohrCirclePlot.pyfor now as they have a more complex structure and did not directly fit this PR but can be treated in a forthcoming onePVPythonViewConfigurator.pyandPVGeosLogReader.pyas they do not fit this refactor