PowerShell / vscode-powershell

Provides PowerShell language and debugging support for Visual Studio Code
https://marketplace.visualstudio.com/items/ms-vscode.PowerShell
MIT License
1.72k stars 494 forks source link

RFC: Standardize Logging Levels and Meanings #5101

Open JustinGrote opened 5 days ago

JustinGrote commented 5 days ago

Prerequisites

Summary

Now that the logging infrastructure has been relatively standardized between vscode-powershell and PSES, I feel like we need to add some logging guidelines to the developer guide, and update severities for existing messages.

Proposed Design

I want there to be specific "layers" that you peel back as you need to investigate an issue, here's my thoughts in order of least verbose to most verbose:

The overarching idea is that anything Debug or above would only contain values/potential PII about the environment itself, whereas trace may include everything the user did or requested including script contents, so users can feel fairly safe about analyzing and submitting debug level reports, whereas trace reports may require some sanitization.

andyleejordan commented 5 days ago

I approve 👍 (I've wanted to clean up and standardize our logging since forever, I did an ok pass on the client a little while ago but the server was still a mess.)