Fix logs still appearing even when LogLevel is set to none bug#3318
Open
RubenCerna2079 wants to merge 38 commits intomainfrom
Open
Fix logs still appearing even when LogLevel is set to none bug#3318RubenCerna2079 wants to merge 38 commits intomainfrom
none bug#3318RubenCerna2079 wants to merge 38 commits intomainfrom
Conversation
This was
linked to
issues
Mar 26, 2026
Contributor
Author
|
/azp run |
Contributor
Author
|
/azp run |
Contributor
Author
|
/azp run |
Aniruddh25
reviewed
Apr 10, 2026
Collaborator
Aniruddh25
left a comment
There was a problem hiding this comment.
Why does the description say we want to fix logs only from dab start? Why not the other commands?
…loglevel-bugs' into dev/rubencerna/fix-loglevel-bugs
3 tasks
Aniruddh25
approved these changes
Apr 16, 2026
Aniruddh25
reviewed
Apr 17, 2026
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.
Why make this change?
Closes issue [Bug]: Startup class logger is not properly initialized #3262
The logger for the Startup class is not initialized properly, since this logger is special due to the nature of the Startup class it needs to be continuously updated as DAB initializes. This causes two problems:
Closes issue [Bug]: CLI logs being outputed even after LogLevel is set to none #3256 & [Bug]:
log-levelseems like it is not working when two in config. #3255The CLI logger still outputs some logs even when the LogLevel is set to
none. It is expected that if the LogLevel set isnoneor some other level that shouldn't output theinformationlevel, the logs will not appear.What is this change?
Important Note: These changes currently only allow us to change the LogLevel from the CLI with the
defaultnamespace in the config file. An task was created to solve this issue: #3451In order to solve issue #3262:
Startup.cs, this is necessary since we wanted each class to have its own LogBuffer so that we are able to tell from which logger the logs are being outputted.Startuplogger by changing the method that it was using to initialize the logger, it now usesCreateLoggerFactoryForHostedAndNonHostedScenariowhich checks if there are any LogLevel namespaces from the config file that can be applicable for the specific logger. It is important to note that there are multiple places where the logs are flushed in order to cover for the cases in which an exception is found and causes DAB to end abruptly, and when we there is an IsLateConfigured scenario.In order to solve issue #3256 & #3255:
StartOptions.csuntil it is able to deserialize the RuntimeConfig and find which level to set theLogLevelin order to flush all the logs.dab startcommand, which is why we only make this change in theStartOptions.csfile, on the functionTryStartEngineWithOptionsinside ofConfigGenerator.cs, and a few functions fromUtils.csandConfigMerger.csthat are used inside theTryStartEnginefunction.How was this tested?
Sample Request(s)