Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Fix resourceCache to return proper modules when PS modules are installed during run#748

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
SteveL-MSFT merged 18 commits intoPowerShell:mainfromGijsreyn:fix-module-add-run-ps
Apr 13, 2025

Conversation

Gijsreyn
Copy link
Contributor

PR Summary

This PR addresses the issue described in#745. When modules are installed during a document being applied, the subsequent modules that are checked in the cache are overwritten. Example:

  1. The first run initiates the resource cache (dsc resource list) as no cache is found.
  2. The first configuration is applied, installing new PowerShell modules (triggering the cache on module paths to be stale).
  3. The assertion triggers theInvoke-DscCacheRefresh -Module '<module>', flushing out the cache with only that particular module.
  4. Modules underneath aren't found anymore in the same sequence.

It's a pretty rough edge case and quite interesting to debug. Nevertheless, there isn't any test added because it would either introduce an external dependency or require internal work to be implemented. Of course, I can be wrong on this and would appreciate some help to write one.

@Gijsreyn
Copy link
ContributorAuthor

Gijsreyn commentedApr 11, 2025
edited
Loading

@SteveL-MSFT, if you have some time, you might taking a glimpse? In the issue, I've also mentioned steps to reproduce it through the module.

Copy link
Member

@SteveL-MSFTSteveL-MSFT left a comment

Choose a reason for hiding this comment

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

Can you repro the original issue by having a test case that executes a test resource that adds a new test resource?

@GijsreynGijsreyn mentioned this pull requestApr 13, 2025
3 tasks
@Gijsreyn
Copy link
ContributorAuthor

Should be good to go@SteveL-MSFT . Workstation did not cooperate today. I hadn't re-requested a review yet, you sharp eye ;)

SteveL-MSFT reacted with thumbs up emoji

@SteveL-MSFTSteveL-MSFT added this pull request to themerge queueApr 13, 2025
Merged via the queue intoPowerShell:main with commit9fc9a80Apr 13, 2025
4 checks passed
@GijsreynGijsreyn deleted the fix-module-add-run-ps branchApril 14, 2025 04:00
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@SteveL-MSFTSteveL-MSFTSteveL-MSFT approved these changes

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@Gijsreyn@SteveL-MSFT

[8]ページ先頭

©2009-2025 Movatter.jp