fix: remove noisy implicit configuration warning from service locator#3837
Open
barjin wants to merge 1 commit into
Open
fix: remove noisy implicit configuration warning from service locator#3837barjin wants to merge 1 commit into
barjin wants to merge 1 commit into
Conversation
The warning fired on every default-configuration usage (e.g. a blank CheerioCrawler), not just the rare case where it would actually matter, confusing beginners into thinking something changed about the expected setup. The debug log already records that a default was created; the actual conflict case is still surfaced via ServiceConflictError if it occurs. Closes #3582
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.
Fixes #3582.
ServiceLocator.getEventManager()/getStorageClient()logged a warning about implicitConfigurationcreation any time it happened before an explicitsetConfiguration()call. That's the normal path for basic usage (nobody setsConfigurationexplicitly by default), so the warning showed up as the first log line in even a blank crawler template, which reads as if something in the setup is wrong when it isn't.Removed the warning; the existing debug log already records that a default was created, and the genuine conflict case (implicit creation followed by a later
setConfiguration()call) still throws a clearServiceConflictError.