Make generated implicit remoting modules backwards compatible with PowerShell 5#17227
Conversation
PaulHigin
left a comment
There was a problem hiding this comment.
This change replaces a string to be executed containing a hardcoded assembly name, with a different string expression that finds the correct type, all to access the script generator version property. This looks like a good change to me. But I would like @daxian-dbw to also take a look.
|
This pull request has been automatically marked as Review Needed because it has been there has not been any activity for 7 days. |
|
This pull request has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 15 days. It will be closed if no further activity occurs within 10 days of this comment. |
|
This pull request has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 15 days. It will be closed if no further activity occurs within 10 days of this comment. |
|
This pull request has been automatically marked as Review Needed because it has been there has not been any activity for 7 days. |
|
Sorry @daxian-dbw, is there anything else for me to do here? |
|
@Tadas As said in my last comment #17227 (comment), I prefer Type type = typeof(ExportPSSessionCommand);
string asmName = type.Assembly.GetName().Name;
string versionOfScriptGenerator = $"[{type.FullName}, {asmName}]::VersionOfScriptGenerator";But this is not a blocking comment, so it's up to @PaulHigin to decide if merging this PR as is. |
|
@daxian-dbw Can you sign off please? |
|
@PaulHigin I have a concern as described in #17227 (comment) and prefer to be explicit about the expected assembly name. But it's not a blocking comment. |
|
@daxian-dbw It is a blocking comment if you don't sign off :). I won't merge until I get two sign offs. If you feel you cannot sign off then please work with the author to remedy. |
|
Alright :) |
|
This PR has Quantification details
Why proper sizing of changes matters
Optimal pull request sizes drive a better predictable PR flow as they strike a
What can I do to optimize my changes
How to interpret the change counts in git diff output
Was this comment helpful? 👍 :ok_hand: :thumbsdown: (Email) |
|
Yep the suggested changes look good 👍 |
|
@Tadas Thank you for your contribution! |
|
🎉 Handy links: |
PR Summary
Make generated implicit remoting modules backwards compatible with PowerShell 5 (Fix #17132)
PR Context
Fixing this issue would allow for a better user experience in environments that haven't been fully migrated to a modern version of PowerShell yet.
PR Checklist
.h,.cpp,.cs,.ps1and.psm1files have the correct copyright headerWIP:or[ WIP ]to the beginning of the title (theWIPbot will keep its status check atPendingwhile the prefix is present) and remove the prefix when the PR is ready.(which runs in a different PS Host).