Skip to content

Conversation

@daxian-dbw
Copy link
Member

PR Summary

Fix #24904

Module loading could happen in PSReadLine module's context because

  1. it may be due to tab completion triggered by PSReadLine,
  2. it may be due to a command run triggered by key-binding press

But that doesn't mean the module should be loaded targeting the PSReadLine module's session state. In this case, we should use the Global session state instead. PSReadLine doesn't depend on any other modules and should not have any module loaded into its session state.

PR Checklist

@daxian-dbw daxian-dbw requested a review from Copilot January 31, 2025 18:39
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot reviewed 1 out of 1 changed files in this pull request and generated no comments.

@daxian-dbw daxian-dbw added the CL-General Indicates that a PR should be marked as a general cmdlet change in the Change Log label Jan 31, 2025
@daxian-dbw
Copy link
Member Author

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 4 pipeline(s).

Copy link
Collaborator

@iSazonov iSazonov left a comment

Choose a reason for hiding this comment

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

LGTM with one minor comment.

@microsoft-github-policy-service microsoft-github-policy-service bot added the Review - Needed The PR is being reviewed label Feb 8, 2025
@iSazonov

This comment was marked as duplicate.

@azure-pipelines

This comment was marked as outdated.

@microsoft-github-policy-service microsoft-github-policy-service bot removed the Review - Needed The PR is being reviewed label Feb 14, 2025
@daxian-dbw daxian-dbw merged commit 1b03005 into PowerShell:master Feb 18, 2025
39 of 41 checks passed
@daxian-dbw daxian-dbw deleted the psrl branch February 18, 2025 18:18
@microsoft-github-policy-service
Copy link
Contributor

microsoft-github-policy-service bot commented Feb 18, 2025

📣 Hey @daxian-dbw, how did we do? We would love to hear your feedback with the link below! 🗣️

🔗 https://aka.ms/PSRepoFeedback

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CL-General Indicates that a PR should be marked as a general cmdlet change in the Change Log

Projects

None yet

Development

Successfully merging this pull request may close these issues.

StackOverflowException when PSReadLine is imported inside another imported module

2 participants