Repository navigation
logger.severe: forward wrap argument to logger.message - #4287
Draft
madhavzanwar wants to merge 1 commit into
Draft
madhavzanwar wants to merge 1 commit into
madhavzanwar wants to merge 1 commit into
Conversation
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.
Description
PEcAn.logger::logger.severe()declareswrap = TRUE(inheriting@inheritParams logger.message) and is called withwrap = FALSEacross PEcAn when printing pre-formatted multi-line tables or error details (check_model_run.R,check_missing_files.R,query_pfts.R,get.trait.data.pft.R,query.prior.R,read.output.R). Becausewrapis matched as a formal parameter oflogger.severe(), passingwrap = FALSEkept it out of..., andlogger.severe()calledlogger.message("SEVERE", msg, ...)without forwardingwrap = wrap.This PR forwards
wrap = wraptologger.message(), adds a regression test inbase/logger/tests/testthat/test.logger.Rverifying bothwrap = FALSE(preserves newlines/spacing without leakingFALSEintostop()) and defaultwrap = TRUE(fails ondevelop, passes with fix), and updatesbase/logger/NEWS.mdandCHANGELOG.md.Motivation and Context
Fixes #4286
Review Time Estimate
Types of changes
Checklist: