Delen via


Resolve-Error

Sends the last error in the current session for resolution in the connected AIShell window.

Syntaxis

Default (Standaard)

Resolve-Error
    [-Agent <String>]
    [-IncludeOutputFromClipboard]
    [<CommonParameters>]

Description

When an error occurs in the current session, this cmdlet sends the error to the AIShell agent for resolution. The command sends the full error object to the current AIShell agent session, which attempts to provide a resolution.

Beginning with theAI Shell v1.0.0-preview.2 release, the Resolve-Error cmdlet also works with error messages output from native commands.

Voorbeelden

Example 1 - Resolves the last error

PS> Start-AIShell
#User receives an error

PS> Resolve-Error

This example shows how to ask AIShell to resolve the last error that occurred in the current AIShell session. AIShell analyzes the error and attempts to provide a solution in the AIShell agent window.

Parameters

-Agent

Specifies the agent to use in the current AIShell session. If not specified, AIShell uses the currently selected agent.

Parametereigenschappen

Type:String
Default value:None
Ondersteunt jokertekens:False
DontShow:False

Parametersets

(All)
Position:Named
Verplicht:False
Waarde uit pijplijn:False
Waarde uit pijplijn op eigenschapsnaam:False
Waarde van resterende argumenten:False

-IncludeOutputFromClipboard

When this parameter is specified, the output copied to the clipboard is included in the error sent to AIShell.

Parametereigenschappen

Type:SwitchParameter
Default value:None
Ondersteunt jokertekens:False
DontShow:False

Parametersets

(All)
Position:Named
Verplicht:False
Waarde uit pijplijn:False
Waarde uit pijplijn op eigenschapsnaam:False
Waarde van resterende argumenten:False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Invoerwaarden

None

Uitvoerwaarden

Object

Notities

PowerShell includes the following alias for this cmdlet:

  • All platforms:
    • fixit