- 
                Notifications
    
You must be signed in to change notification settings  - Fork 936
 
Avoid setLevel in child when possible #2271
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
          
     Merged
      
      
    
                
     Merged
            
            
          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
    
  
  
    
    Signed-off-by: Matteo Collina <[email protected]>
              
                    ronag
  
              
              approved these changes
              
                  
                    Sep 4, 2025 
                  
              
              
            
            
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Helps a lot!
              
                    kibertoad
  
              
              approved these changes
              
                  
                    Sep 4, 2025 
                  
              
              
            
            
              
                    jsumners
  
              
              approved these changes
              
                  
                    Sep 4, 2025 
                  
              
              
            
            
    
  BugBareDrums 
      added a commit
        to DEFRA/grants-ui
      that referenced
      this pull request
    
      Sep 29, 2025 
    
    
      
  
    
      
    
  
 <h3>Snyk has created this PR to upgrade pino from 9.9.2 to 9.9.4.</h3> :information_source: Keep your dependencies up-to-date. This makes it easier to fix existing vulnerabilities and to more quickly identify and fix newly disclosed vulnerabilities when they affect your project. <hr/> - The recommended version is **2 versions** ahead of your current version. - The recommended version was released **22 days ago**. <details> <summary><b>Release notes</b></summary> <br/> <details> <summary>Package name: <b>pino</b></summary> <ul> <li> <b>9.9.4</b> - <a href="https://redirect.github.com/pinojs/pino/releases/tag/v9.9.4">2025-09-05</a></br><h2>What's Changed</h2> <ul> <li>fix(logfn): use unknown type by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/rozzilla/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/rozzilla">@ rozzilla</a> in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3387481502" data-permission-text="Title is private" data-url="pinojs/pino#2276" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2276/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2276">#2276</a></li> </ul> <p><strong>Full Changelog</strong>: <a class="commit-link" href="https://redirect.github.com/pinojs/pino/compare/v9.9.3...v9.9.4"><tt>v9.9.3...v9.9.4</tt></a></p> </li> <li> <b>9.9.3</b> - <a href="https://redirect.github.com/pinojs/pino/releases/tag/v9.9.3">2025-09-05</a></br><h2>What's Changed</h2> <ul> <li>fix(types): compatibility when leveraging parameters by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/rozzilla/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/rozzilla">@ rozzilla</a> in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3386970739" data-permission-text="Title is private" data-url="pinojs/pino#2273" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2273/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2273">#2273</a></li> </ul> <h2>New Contributors</h2> <ul> <li><a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/rozzilla/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/rozzilla">@ rozzilla</a> made their first contribution in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3386970739" data-permission-text="Title is private" data-url="pinojs/pino#2273" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2273/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2273">#2273</a></li> </ul> <p><strong>Full Changelog</strong>: <a class="commit-link" href="https://redirect.github.com/pinojs/pino/compare/v9.9.2...v9.9.3"><tt>v9.9.2...v9.9.3</tt></a></p> </li> <li> <b>9.9.2</b> - <a href="https://redirect.github.com/pinojs/pino/releases/tag/v9.9.2">2025-09-04</a></br><h2>What's Changed</h2> <ul> <li>Avoid setLevel in child when possible by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/mcollina/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/mcollina">@ mcollina</a> in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3382881237" data-permission-text="Title is private" data-url="pinojs/pino#2271" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2271/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2271">#2271</a></li> </ul> <p><strong>Full Changelog</strong>: <a class="commit-link" href="https://redirect.github.com/pinojs/pino/compare/v9.9.1...v9.9.2"><tt>v9.9.1...v9.9.2</tt></a></p> </li> </ul> from <a href="https://redirect.github.com/pinojs/pino/releases">pino GitHub release notes</a> </details> </details> --- > [!IMPORTANT] > > - Check the changes in this PR to ensure they won't cause issues with your project. > - This PR was automatically created by Snyk using the credentials of a real user. --- **Note:** _You are seeing this because you or someone else with access to this repository has authorized Snyk to open upgrade PRs._ **For more information:** <img src="https://api.segment.io/v1/pixel/track?data=eyJ3cml0ZUtleSI6InJyWmxZcEdHY2RyTHZsb0lYd0dUcVg4WkFRTnNCOUEwIiwiYW5vbnltb3VzSWQiOiI1ODYxYmI5MC1jODlhLTQ1MWUtYWI5My0wMTg3MTRkNmMxNzgiLCJldmVudCI6IlBSIHZpZXdlZCIsInByb3BlcnRpZXMiOnsicHJJZCI6IjU4NjFiYjkwLWM4OWEtNDUxZS1hYjkzLTAxODcxNGQ2YzE3OCJ9fQ==" width="0" height="0"/> > - 🧐 [View latest project report](https://app.snyk.io/org/alanplatt/project/ff50773c-5262-40d8-b38d-68f56510f59a?utm_source=github&utm_medium=referral&page=upgrade-pr) > - 📜 [Customise PR templates](https://docs.snyk.io/scan-using-snyk/pull-requests/snyk-fix-pull-or-merge-requests/customize-pr-templates?utm_source=&utm_content=fix-pr-template) > - 🛠 [Adjust upgrade PR settings](https://app.snyk.io/org/alanplatt/project/ff50773c-5262-40d8-b38d-68f56510f59a/settings/integration?utm_source=github&utm_medium=referral&page=upgrade-pr) > - 🔕 [Ignore this dependency or unsubscribe from future upgrade PRs](https://app.snyk.io/org/alanplatt/project/ff50773c-5262-40d8-b38d-68f56510f59a/settings/integration?pkg=pino&utm_source=github&utm_medium=referral&page=upgrade-pr#auto-dep-upgrades) [//]: # 'snyk:metadata:{"breakingChangeRiskLevel":null,"FF_showPullRequestBreakingChanges":null,"FF_showPullRequestBreakingChangesWebSearch":null,"customTemplate":{"variablesUsed":[],"fieldsUsed":[]},"dependencies":[{"name":"pino","from":"9.9.2","to":"9.9.4"}],"env":"prod","hasFixes":false,"isBreakingChange":false,"isMajorUpgrade":false,"issuesToFix":[],"prId":"5861bb90-c89a-451e-ab93-018714d6c178","prPublicId":"5861bb90-c89a-451e-ab93-018714d6c178","packageManager":"npm","priorityScoreList":[],"projectPublicId":"ff50773c-5262-40d8-b38d-68f56510f59a","projectUrl":"https://app.snyk.io/org/alanplatt/project/ff50773c-5262-40d8-b38d-68f56510f59a?utm_source=github&utm_medium=referral&page=upgrade-pr","prType":"upgrade","templateFieldSources":{"branchName":"default","commitMessage":"default","description":"default","title":"default"},"templateVariants":[],"type":"auto","upgrade":[],"upgradeInfo":{"versionsDiff":2,"publishedDate":"2025-09-05T13:38:58.265Z"},"vulns":[]}'
    
  Blankll 
      added a commit
        to geek-fun/serverlessinsight
      that referenced
      this pull request
    
      Oct 9, 2025 
    
    
      
  
    
      
    
  
 <h3>Snyk has created this PR to upgrade pino from 9.9.0 to 9.9.4.</h3> :information_source: Keep your dependencies up-to-date. This makes it easier to fix existing vulnerabilities and to more quickly identify and fix newly disclosed vulnerabilities when they affect your project. <hr/> - The recommended version is **4 versions** ahead of your current version. - The recommended version was released **23 days ago**. <details> <summary><b>Release notes</b></summary> <br/> <details> <summary>Package name: <b>pino</b></summary> <ul> <li> <b>9.9.4</b> - <a href="https://redirect.github.com/pinojs/pino/releases/tag/v9.9.4">2025-09-05</a></br><h2>What's Changed</h2> <ul> <li>fix(logfn): use unknown type by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/rozzilla/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/rozzilla">@ rozzilla</a> in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3387481502" data-permission-text="Title is private" data-url="pinojs/pino#2276" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2276/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2276">#2276</a></li> </ul> <p><strong>Full Changelog</strong>: <a class="commit-link" href="https://redirect.github.com/pinojs/pino/compare/v9.9.3...v9.9.4"><tt>v9.9.3...v9.9.4</tt></a></p> </li> <li> <b>9.9.3</b> - <a href="https://redirect.github.com/pinojs/pino/releases/tag/v9.9.3">2025-09-05</a></br><h2>What's Changed</h2> <ul> <li>fix(types): compatibility when leveraging parameters by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/rozzilla/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/rozzilla">@ rozzilla</a> in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3386970739" data-permission-text="Title is private" data-url="pinojs/pino#2273" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2273/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2273">#2273</a></li> </ul> <h2>New Contributors</h2> <ul> <li><a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/rozzilla/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/rozzilla">@ rozzilla</a> made their first contribution in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3386970739" data-permission-text="Title is private" data-url="pinojs/pino#2273" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2273/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2273">#2273</a></li> </ul> <p><strong>Full Changelog</strong>: <a class="commit-link" href="https://redirect.github.com/pinojs/pino/compare/v9.9.2...v9.9.3"><tt>v9.9.2...v9.9.3</tt></a></p> </li> <li> <b>9.9.2</b> - <a href="https://redirect.github.com/pinojs/pino/releases/tag/v9.9.2">2025-09-04</a></br><h2>What's Changed</h2> <ul> <li>Avoid setLevel in child when possible by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/mcollina/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/mcollina">@ mcollina</a> in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3382881237" data-permission-text="Title is private" data-url="pinojs/pino#2271" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2271/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2271">#2271</a></li> </ul> <p><strong>Full Changelog</strong>: <a class="commit-link" href="https://redirect.github.com/pinojs/pino/compare/v9.9.1...v9.9.2"><tt>v9.9.1...v9.9.2</tt></a></p> </li> <li> <b>9.9.1</b> - <a href="https://redirect.github.com/pinojs/pino/releases/tag/v9.9.1">2025-09-03</a></br><h2>What's Changed</h2> <ul> <li>build(deps): bump actions/checkout from 4 to 5 by <a class="user-mention notranslate" data-hovercard-type="organization" data-hovercard-url="/orgs/dependabot/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/dependabot">@ dependabot</a>[bot] in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3374109350" data-permission-text="Title is private" data-url="pinojs/pino#2268" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2268/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2268">#2268</a></li> <li>build(deps-dev): bump tsd from 0.32.0 to 0.33.0 by <a class="user-mention notranslate" data-hovercard-type="organization" data-hovercard-url="/orgs/dependabot/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/dependabot">@ dependabot</a>[bot] in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3374279692" data-permission-text="Title is private" data-url="pinojs/pino#2269" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2269/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2269">#2269</a></li> <li>fix: TypeScript regression with boolean values in %s placeholders by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/mcollina/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/mcollina">@ mcollina</a> in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3332248631" data-permission-text="Title is private" data-url="pinojs/pino#2262" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2262/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2262">#2262</a></li> </ul> <p><strong>Full Changelog</strong>: <a class="commit-link" href="https://redirect.github.com/pinojs/pino/compare/v9.9.0...v9.9.1"><tt>v9.9.0...v9.9.1</tt></a></p> </li> <li> <b>9.9.0</b> - <a href="https://redirect.github.com/pinojs/pino/releases/tag/v9.9.0">2025-08-13</a></br><h2>What's Changed</h2> <ul> <li>Fix TypeScript types by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/joshkel/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/joshkel">@ joshkel</a> in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3311444435" data-permission-text="Title is private" data-url="pinojs/pino#2258" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2258/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2258">#2258</a></li> <li>feat: Added remove to multistream. by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/ShogunPanda/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://redirect.github.com/ShogunPanda">@ ShogunPanda</a> in <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="3309985149" data-permission-text="Title is private" data-url="pinojs/pino#2257" data-hovercard-type="pull_request" data-hovercard-url="/pinojs/pino/pull/2257/hovercard" href="https://redirect.github.com/pinojs/pino/pull/2257">#2257</a></li> </ul> <p><strong>Full Changelog</strong>: <a class="commit-link" href="https://redirect.github.com/pinojs/pino/compare/v9.8.0...v9.9.0"><tt>v9.8.0...v9.9.0</tt></a></p> </li> </ul> from <a href="https://redirect.github.com/pinojs/pino/releases">pino GitHub release notes</a> </details> </details> --- > [!IMPORTANT] > > - Check the changes in this PR to ensure they won't cause issues with your project. > - This PR was automatically created by Snyk using the credentials of a real user. --- **Note:** _You are seeing this because you or someone else with access to this repository has authorized Snyk to open upgrade PRs._ **For more information:** <img src="https://api.segment.io/v1/pixel/track?data=eyJ3cml0ZUtleSI6InJyWmxZcEdHY2RyTHZsb0lYd0dUcVg4WkFRTnNCOUEwIiwiYW5vbnltb3VzSWQiOiI4NzA2ZmM3Zi03OTc2LTRkYjEtYmI0NC1hY2ZiMjg4ZDFiNjEiLCJldmVudCI6IlBSIHZpZXdlZCIsInByb3BlcnRpZXMiOnsicHJJZCI6Ijg3MDZmYzdmLTc5NzYtNGRiMS1iYjQ0LWFjZmIyODhkMWI2MSJ9fQ==" width="0" height="0"/> > - 🧐 [View latest project report](https://app.snyk.io/org/blankll/project/9c72c875-e7a2-4e68-85a9-7b26a5bc5b32?utm_source=github&utm_medium=referral&page=upgrade-pr) > - 📜 [Customise PR templates](https://docs.snyk.io/scan-using-snyk/pull-requests/snyk-fix-pull-or-merge-requests/customize-pr-templates?utm_source=&utm_content=fix-pr-template) > - 🛠 [Adjust upgrade PR settings](https://app.snyk.io/org/blankll/project/9c72c875-e7a2-4e68-85a9-7b26a5bc5b32/settings/integration?utm_source=github&utm_medium=referral&page=upgrade-pr) > - 🔕 [Ignore this dependency or unsubscribe from future upgrade PRs](https://app.snyk.io/org/blankll/project/9c72c875-e7a2-4e68-85a9-7b26a5bc5b32/settings/integration?pkg=pino&utm_source=github&utm_medium=referral&page=upgrade-pr#auto-dep-upgrades) [//]: # 'snyk:metadata:{"breakingChangeRiskLevel":null,"FF_showPullRequestBreakingChanges":null,"FF_showPullRequestBreakingChangesWebSearch":null,"customTemplate":{"variablesUsed":[],"fieldsUsed":[]},"dependencies":[{"name":"pino","from":"9.9.0","to":"9.9.4"}],"env":"prod","hasFixes":false,"isBreakingChange":false,"isMajorUpgrade":false,"issuesToFix":[],"prId":"8706fc7f-7976-4db1-bb44-acfb288d1b61","prPublicId":"8706fc7f-7976-4db1-bb44-acfb288d1b61","packageManager":"npm","priorityScoreList":[],"projectPublicId":"9c72c875-e7a2-4e68-85a9-7b26a5bc5b32","projectUrl":"https://app.snyk.io/org/blankll/project/9c72c875-e7a2-4e68-85a9-7b26a5bc5b32?utm_source=github&utm_medium=referral&page=upgrade-pr","prType":"upgrade","templateFieldSources":{"branchName":"default","commitMessage":"default","description":"default","title":"default"},"templateVariants":[],"type":"auto","upgrade":[],"upgradeInfo":{"versionsDiff":4,"publishedDate":"2025-09-05T13:38:58.265Z"},"vulns":[]}' Co-authored-by: snyk-bot <[email protected]>
    
  mcollina 
      added a commit
      that referenced
      this pull request
    
      Oct 18, 2025 
    
    
      
  
    
      
    
  
* Revert "Avoid setLevel in child when possible (#2271)" This reverts commit d6114a6. * fix: ensure child loggers get own method references when level is explicitly set When creating a child logger with an explicit level option (even if same as parent), always call setLevel to ensure the child gets its own method references instead of inheriting from the parent prototype. This prevents issues when parent methods are wrapped by testing libraries like Sinon. Fixes #2287 Signed-off-by: Matteo Collina <[email protected]> --------- Signed-off-by: Matteo Collina <[email protected]>
  
    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.
  
    
  
    
Uh oh!
There was an error while loading. Please reload this page.