Skip to content
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

Add better tracing and fix propagation of inDesiredState for PSAdapter #699

Merged
merged 1 commit into from
Mar 17, 2025

Conversation

SteveL-MSFT
Copy link
Member

PR Summary

  • Tracing wasn't correct due to case-sensitivity of JSON and some traces were being written directly instead of through the helper
  • Simple tracing should be lowercase and be warn instead of warning
  • Add _inDesiredState property to the result object for test if any of the results contain InDesiredState and only true if all are true

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

The PR updates the JSON key names used in logging to ensure proper trace level mapping and consistency.

  • Converted JSON keys for error, warn, info, debug, and trace from uppercase to lowercase.
  • Ensured the logger calls correctly use the lower-case keys as specified.
@SteveL-MSFT SteveL-MSFT force-pushed the ps-adapter-desiredstate branch from 12b423a to 92c60fa Compare March 14, 2025 21:54
@SteveL-MSFT
Copy link
Member Author

SteveL-MSFT commented Mar 16, 2025

Need to make one more change to rename InDesiredState to _inDesiredState at the resource level to keep it consistent

Edit: Actually, maybe we'll keep it as-is for now so there's no manipulation of the source

@SteveL-MSFT SteveL-MSFT added this pull request to the merge queue Mar 17, 2025
Merged via the queue into PowerShell:main with commit 7857e5a Mar 17, 2025
4 checks passed
@SteveL-MSFT SteveL-MSFT deleted the ps-adapter-desiredstate branch March 17, 2025 17:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants