Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@

# ignore the settings folder and files for VSCode and PSS
.vscode/*
*.psproj
*TempPoint*

Expand Down
11 changes: 11 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"editor.detectIndentation": false,
"editor.insertSpaces": false,
"powershell.codeFormatting.pipelineIndentationStyle": "IncreaseIndentationAfterEveryPipeline",
"powershell.codeFormatting.trimWhitespaceAroundPipe": true,
"powershell.codeFormatting.whitespaceBetweenParameters": true,
"powershell.codeFormatting.autoCorrectAliases": true,
"powershell.codeFormatting.useCorrectCasing": true,

"files.encoding": "utf8bom",
}
3 changes: 2 additions & 1 deletion PSFramework/PSFramework.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
RootModule = 'PSFramework.psm1'

# Version number of this module.
ModuleVersion = '1.13.406'
ModuleVersion = '1.13.414'

# ID used to uniquely identify this module
GUID = '8028b914-132b-431f-baa9-94a6952f21ff'
Expand Down Expand Up @@ -95,6 +95,7 @@
'Install-PSFLoggingProvider'
'Invoke-PSFCommand'
'Invoke-PSFFilter'
'Invoke-PSFRunspace'
'Join-PSFPath'
'New-PSFFilter'
'New-PSFFilterCondition'
Expand Down
Binary file removed PSFramework/PSFramework.psproj.psbuild
Binary file not shown.
Binary file modified PSFramework/bin/PSFramework.dll
Binary file not shown.
Binary file modified PSFramework/bin/PSFramework.pdb
Binary file not shown.
297 changes: 297 additions & 0 deletions PSFramework/bin/PSFramework.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8573,6 +8573,49 @@
Purge all RBVs of datasets from all expired runspaces
</summary>
</member>
<member name="T:PSFramework.Runspace.RunspaceResult">
<summary>
The result of a runspace task
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceResult.InputObject">
<summary>
The object that triggered the task
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceResult.Output">
<summary>
All output
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceResult.Information">
<summary>
All Information Messages
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceResult.Verbose">
<summary>
All verbose messages
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceResult.Warnings">
<summary>
All warning messages
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceResult.Errors">
<summary>
All error records
</summary>
</member>
<member name="M:PSFramework.Runspace.RunspaceResult.#ctor(System.Object,System.Management.Automation.PSDataCollection{System.Management.Automation.PSObject},System.Management.Automation.PSDataStreams)">
<summary>
Creates a result object, representing the completed result of the runspace task.
</summary>
<param name="InputObject">The original argument for the task</param>
<param name="Output">The output result of the task</param>
<param name="Streams">The streams the task sent</param>
</member>
<member name="T:PSFramework.Runspace.PsfRunspaceState">
<summary>
Contains the state a managed, unique runspace can be in.
Expand All @@ -8593,6 +8636,245 @@
The runspace has followed its order to stop and is currently disabled
</summary>
</member>
<member name="T:PSFramework.Runspace.RunspaceTask">
<summary>
An individual task executed in the runspace pool of its hosting RunspaceWrapper
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceTask.InputObject">
<summary>
The item to process in this task
</summary>
</member>
<member name="P:PSFramework.Runspace.RunspaceTask.IsCompleted">
<summary>
Whether the task has completed successfully
</summary>
</member>
<member name="M:PSFramework.Runspace.RunspaceTask.#ctor(PSFramework.Runspace.RunspaceWrapper,System.Object)">
<summary>
Create a new runspace task. If the host has already stared execution, it is immediately queued for execution.
</summary>
<param name="Host">The hosting RunspaceWrapper</param>
<param name="InputObject">The item to process in this task</param>
</member>
<member name="M:PSFramework.Runspace.RunspaceTask.TryCollect(System.Management.Automation.Cmdlet,System.Boolean)">
<summary>
If the task is complete, collect results and direct the streams. Do nothing if not complete yet.
Delists itself from the hosting RunspaceWrapper, if completed.
</summary>
<param name="Command">The command runtime to whose streams to write the results</param>
<param name="NoStreams">Do not write to additional streams</param>
<returns>Whether it successfully collected the results</returns>
</member>
<member name="M:PSFramework.Runspace.RunspaceTask.CollectResult">
<summary>
Wait until the task completes, then get the full result with all stream information
</summary>
<returns>A result object, containing output and streams</returns>
<exception cref="T:System.InvalidOperationException">Don't try to collect results before starting the task</exception>
</member>
<member name="M:PSFramework.Runspace.RunspaceTask.Collect">
<summary>
Wait until the task completes, then get the output
</summary>
<returns>All output results of the task</returns>
<exception cref="T:System.InvalidOperationException">Don't try to collect results before starting the task</exception>
</member>
<member name="M:PSFramework.Runspace.RunspaceTask.Collect(System.Management.Automation.Cmdlet,System.Boolean)">
<summary>
Wait until the task completes, then collect results and direct the streams.
</summary>
<param name="Command">The command runtime to whose streams to write the results</param>
<param name="NoStreams">hether to NOT write to the different streams.</param>
<exception cref="T:System.InvalidOperationException">Don't try to collect results before starting the task</exception>
</member>
<member name="M:PSFramework.Runspace.RunspaceTask.Start">
<summary>
Start this task, queueing the code as a runspace in the runspace pool for execution
</summary>
<exception cref="T:System.InvalidOperationException">If the runspacepool of the hosting RunspaceWrapper has not been opened yet, we cannot start yet</exception>
</member>
<member name="M:PSFramework.Runspace.RunspaceTask.Kill">
<summary>
Cancel and destroy this task.
</summary>
</member>
<member name="M:PSFramework.Runspace.RunspaceTask.Dispose">
<summary>
Clean up this object
</summary>
</member>
<member name="T:PSFramework.Runspace.RunspaceWrapper">
<summary>
Runspace managing class used by Invoke-PSFRunspace.
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceWrapper.Name">
<summary>
Nme of the workload
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceWrapper.Code">
<summary>
The code to run in parallel
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceWrapper.ThrottleLimit">
<summary>
How many runspace tasks to execute in parallel
</summary>
</member>
<member name="P:PSFramework.Runspace.RunspaceWrapper.CountTotal">
<summary>
Total number of tasks in this wrapper
</summary>
</member>
<member name="P:PSFramework.Runspace.RunspaceWrapper.CountPending">
<summary>
Number of Tasks still pending
</summary>
</member>
<member name="P:PSFramework.Runspace.RunspaceWrapper.CountCompleted">
<summary>
Number of Tasks completed
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceWrapper.InitialSessionState">
<summary>
What each runspace task will have available
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceWrapper.Tasks">
<summary>
List of tasks to execute
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceWrapper.Variables">
<summary>
Variables available to all tasks
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceWrapper.Functions">
<summary>
Functions available to all tasks
</summary>
</member>
<member name="F:PSFramework.Runspace.RunspaceWrapper.Modules">
<summary>
Modules available to all tasks
</summary>
</member>
<member name="P:PSFramework.Runspace.RunspaceWrapper.IsRunning">
<summary>
Whether the RunspaceWrapper is currently open for tasks
</summary>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.AddVariable(System.String,System.Object)">
<summary>
Add a variable to the initial sessionstate
</summary>
<param name="Name">name of the variable</param>
<param name="Value">Value of the variable</param>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.AddVariable(System.Collections.Hashtable)">
<summary>
Add multiple variables to the initial sessionstate
</summary>
<param name="VariableHash">Name/value map of variables to inclue</param>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.AddModule(System.String)">
<summary>
Add a module by name or path
</summary>
<param name="Module">Name or path to the module</param>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.AddModule(System.Management.Automation.PSModuleInfo)">
<summary>
Add a module by its module info object
</summary>
<param name="Module">The module info object</param>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.AddFunction(System.String,System.Management.Automation.ScriptBlock)">
<summary>
Define a function available to all tasks
</summary>
<param name="Name"></param>
<param name="Definition"></param>
<exception cref="T:System.Management.Automation.PSSecurityException"></exception>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.AddFunction(System.Management.Automation.FunctionInfo)">
<summary>
Define a function available to all tasks
</summary>
<param name="Function">Function info object to copy over</param>
<exception cref="T:System.Management.Automation.PSSecurityException"></exception>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.Start">
<summary>
Start the entire wrapper, creating a runspace pool and preparing for execution
</summary>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.Stop">
<summary>
Close the runspace pool, terminate everything and clean up.
</summary>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.Dispose">
<summary>
Make sure everything is cleaned out after the job is done
</summary>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.AddTask(System.Object)">
<summary>
Add a task that should be executed
</summary>
<param name="InputObject">The argument for which the task should be executed</param>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.AddTaskBulk(System.Collections.IEnumerable)">
<summary>
Add a list of tasks that all should be executed
</summary>
<param name="InputObjects">The arugments for each of which the task should be executed</param>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.Collect(System.Management.Automation.Cmdlet,System.Boolean)">
<summary>
Wait for all task results and receive results directly into the streams of the calling command
</summary>
<param name="Command">The command runtime whose streams to write to</param>
<param name="NoStreams">Whether additional streams should be hidden and only output shown</param>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.CollectCurrent(System.Management.Automation.Cmdlet,System.Boolean)">
<summary>
Collect all tasks that already completed, and directly write the results to the streams of the calling command
</summary>
<param name="Command">The command runtime whose streams to write to</param>
<param name="NoStreams">Whether additional streams should be hidden and only output shown</param>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.CollectResult">
<summary>
Wait for all task results and return result report objects, including information on all streams of the runspace
</summary>
<returns>List of completion reports, including all output, warnings, errors, informational messages, etc.</returns>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.CollectCurrentResult">
<summary>
Retrieve result report objects for each task already completed, including information on all streams of the runspace
</summary>
<returns>List of completion reports, including all output, warnings, errors, informational messages, etc.</returns>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.Collect">
<summary>
Wait for all task results and return the output.
</summary>
<returns>The resulting output of all tasks</returns>
</member>
<member name="M:PSFramework.Runspace.RunspaceWrapper.CollectCurrent">
<summary>
Receive the output of all currently completed tasks
</summary>
<returns>The output of all currently completed tasks</returns>
</member>
<member name="T:PSFramework.Serialization.ClixmlDataStyle">
<summary>
The serialization output options available
Expand Down Expand Up @@ -8927,6 +9209,16 @@
Whether to execute the scriptblock in the global scope
</summary>
</member>
<member name="F:PSFramework.TabExpansion.ScriptContainer.DoNotFilter">
<summary>
When enabled, do not filter based on user input.
</summary>
</member>
<member name="P:PSFramework.TabExpansion.ScriptContainer.MaxResults">
<summary>
Maximum number of results to show when tab-completing.
</summary>
</member>
<member name="P:PSFramework.TabExpansion.ScriptContainer.MatchAnywhere">
<summary>
If true: Match input against any part of the options, not just the beginning
Expand Down Expand Up @@ -9030,6 +9322,11 @@
Whether PSFramework completion should use fuzzy-matching when matching completion values with the already typed text.
</summary>
</member>
<member name="F:PSFramework.TabExpansion.TabExpansionHost.MaxResults">
<summary>
The maximum number of results shown to the user, before truncating data sets.
</summary>
</member>
<member name="M:PSFramework.TabExpansion.TabExpansionHost.RegisterCompletion(System.String,System.Management.Automation.ScriptBlock,PSFramework.TabExpansion.TeppScriptMode,PSFramework.Parameter.TimeSpanParameter,System.Boolean)">
<summary>
Registers a new completion scriptblock
Expand Down
11 changes: 11 additions & 0 deletions PSFramework/changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
# CHANGELOG

## 1.13.414 (2025-10-14)

- Upd: Wait-PSFRunspaceWorkflow - adding ProgressBar with `-ShowProgress` (#698 | @fslef)
- Upd: Register-PSFArgumentCompleter - adding parameter `-DontFilter`, disabling automatic filtering by user input and enabling complex custom filtering inside of the completer (#696)
- Upd: Register-PSFArgumentCompleter - adding parameter `-MaxResults`, truncating large result-sets for a more userfriendly display (#694)
- Fix: Invoke-PSFProtectedCommand - $paramStopPSFFunction Leaks To Global Scope (#697)
- Fix: Register-PSFArgumentCompleter - ignores `-DontSort`
- Fix: Configuration import - simple persistence from Environment fails for arrays (#692)
- Fix: ConvertTo-PSFPsd1 - Error: The property 'Depth' cannot be found on this object (#695)
- Fix: Filter "Environment" - "Elevated" miss-detects MacOS (#693)

## 1.13.406 (2025-08-29)

- New: Assert-PSFInternalCommand - Verifies, that the command calling it in turn was only called from another command within the same module. (#685)
Expand Down
4 changes: 4 additions & 0 deletions PSFramework/en-us/stringsRunspaces.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
'Add-PSFRunspaceWorker.Error.UntrustedFunctionCode' = 'Failed to load function {0}: The provided function code is not trusted (in Constrained language Mode) and cannot be imported. Ensure the code building the scriptblock is trusted to create a non-constrained scriptblock.' # $pair.Key
'Add-PSFRunspaceWorker.Error.UntrustedTextFunction' = 'Failed to load function {0}: String-based code is not trusted in a secured console. Provide its code as a scriptblock, rather than a string to enable code trust verification.' # $pair.Key

'Invoke-PSFRunspace.Error.ModuleImport' = 'Failed to include module: "{0}"' # $module
'Invoke-PSFRunspace.Error.UntrustedTextFunction' = 'Failed to import function "{0}". Providing function-code as text is not supported in a hardened PowerShell process. Provide the function-code instead as a scriptblock.' # $pair.Key
'Invoke-PSFRunspace.Error.UntrustedFunctionCode' = 'Failed to import function "{0}". Scriptblock is not in FullLanguage mode and thus not trusted!' # $pair.Key

'New-PSFRunspaceWorkflow.Error.ExistsAlready' = 'Failed to create workflow {0}: It already exists! Use "-Force" to overwrite the existing Runspace Workflow, interrupting all currently ongoing processing.' # $Name

'Read-PSFRunspaceQueue.Error.Continual.TooManyWorkflows' = 'Error resolving queue to read from in continuous mode: {0}. Multiple workflows found, while continuous read only supports a single workflow. Workflows found: {1}' # $Name, ($resolvedWorkflows.Name -join ', ')
Expand Down
2 changes: 1 addition & 1 deletion PSFramework/functions/data/ConvertTo-PSFPsd1.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
)
begin {
$converter = [PSFramework.Data.Psd1Converter]::new()
$converter.Depth = $Depth
$converter.MaxDepth = $Depth
$converter.EnableVerbose = $EnableVerbose
$converter.Config = $Configuration
$converter.Cmdlet = $PSCmdlet
Expand Down
Loading