-
Notifications
You must be signed in to change notification settings - Fork 100
Open
Labels
Description
Prerequisites
- Write a descriptive title.
- Make sure you are able to repro it on the latest released version
- Search the existing issues.
Steps to reproduce
- Execute 'Save-PsResource Az'
Expected behavior
Az Module is savedActual behavior
Cmdlet fails with 500 errorError details
PS E:\pwsh-modules> get-error
Type : System.Management.Automation.ActionPreferenceStopException
ErrorRecord :
Exception :
Type : System.Net.Http.HttpRequestException
TargetSite :
Name : MoveNext
DeclaringType : [Microsoft.PowerShell.PSResourceGet.Cmdlets.V2ServerAPICalls+<SendV2RequestAsync>d__37]
MemberType : Method
Module : Microsoft.PowerShell.PSResourceGet.dll
Message : 'Response status code does not indicate success: 500 (Internal Server Error).' Request sent: 'https://www.powershellgallery.com/api/v2/FindPackagesById()?%24filter=NormalizedVersion+ge+%275.0.1%27
+and+NormalizedVersion+le+%275.0.19%27+and+Id+eq+%27Az.ContainerRegistry%27&%24inlinecount=allpages&%24skip=0&%24orderby=NormalizedVersion+desc&id=%27Az.ContainerRegistry%27'
Source : Microsoft.PowerShell.PSResourceGet
HResult : -2146233088
StackTrace :
at Microsoft.PowerShell.PSResourceGet.Cmdlets.V2ServerAPICalls.SendV2RequestAsync(HttpRequestMessage message, HttpClient s_client) in C:\__w\1\s\PSResourceGet\src\code\V2ServerAPICalls.cs:line 1535
at Microsoft.PowerShell.PSResourceGet.Cmdlets.V2ServerAPICalls.HttpRequestCall(String requestUrlV2, ErrorRecord& errRecord) in C:\__w\1\s\PSResourceGet\src\code\V2ServerAPICalls.cs:line 800
TargetObject : Microsoft.PowerShell.PSResourceGet.Cmdlets.V2ServerAPICalls
CategoryInfo : ConnectionError: (Microsoft.PowerShel…ts.V2ServerAPICalls:V2ServerAPICalls) [Save-PSResource], HttpRequestException
FullyQualifiedErrorId : HttpRequestCallFailure,Microsoft.PowerShell.PSResourceGet.Cmdlets.SavePSResource
InvocationInfo :
MyCommand : Save-PSResource
ScriptLineNumber : 1
OffsetInLine : 1
HistoryId : 4
Line : Save-PsResource Az
Statement : Save-PsResource Az
PositionMessage : At line:1 char:1
+ Save-PsResource Az
+ ~~~~~~~~~~~~~~~~~~
InvocationName : Save-PsResource
CommandOrigin : Internal
ScriptStackTrace : at <ScriptBlock>, <No file>: line 1
PipelineIterationInfo :
0
1
TargetSite :
Name : Invoke
DeclaringType : [System.Management.Automation.Runspaces.PipelineBase]
MemberType : Method
Module : System.Management.Automation.dll
Message : The running command stopped because the preference variable "ErrorActionPreference" or common parameter is set to Stop: 'Response status code does not indicate success: 500 (Internal Server Error).'
Request sent: 'https://www.powershellgallery.com/api/v2/FindPackagesById()?%24filter=NormalizedVersion+ge+%275.0.1%27+and+NormalizedVersion+le+%275.0.19%27+and+Id+eq+%27Az.ContainerRegistry%27&%24inlinecount=allpages&
%24skip=0&%24orderby=NormalizedVersion+desc&id=%27Az.ContainerRegistry%27'
Data : System.Collections.ListDictionaryInternal
Source : System.Management.Automation
HResult : -2146233087
StackTrace :
at System.Management.Automation.Runspaces.PipelineBase.Invoke(IEnumerable input)
at System.Management.Automation.PowerShell.Worker.ConstructPipelineAndDoWork(Runspace rs, Boolean performSyncInvoke)
at System.Management.Automation.PowerShell.Worker.CreateRunspaceIfNeededAndDoWork(Runspace rsToUse, Boolean isSync)
at System.Management.Automation.PowerShell.CoreInvokeHelper[TInput,TOutput](PSDataCollection`1 input, PSDataCollection`1 output, PSInvocationSettings settings)
at System.Management.Automation.PowerShell.CoreInvoke[TInput,TOutput](PSDataCollection`1 input, PSDataCollection`1 output, PSInvocationSettings settings)
at System.Management.Automation.PowerShell.Invoke[T](IEnumerable input, PSInvocationSettings settings)
at Microsoft.PowerShell.EditorServices.Services.PowerShell.Utility.PowerShellExtensions.InvokeAndClear[TResult](PowerShell pwsh, PSInvocationSettings invocationSettings) in
C:\__w\1\s\src\PowerShellEditorServices\Services\PowerShell\Utility\PowerShellExtensions.cs:line 76
at Microsoft.PowerShell.EditorServices.Services.PowerShell.Utility.PowerShellExtensions.InvokeCommand[TResult](PowerShell pwsh, PSCommand psCommand, PSInvocationSettings invocationSettings) in
C:\__w\1\s\src\PowerShellEditorServices\Services\PowerShell\Utility\PowerShellExtensions.cs:line 99
at Microsoft.PowerShell.EditorServices.Services.PowerShell.Execution.SynchronousPowerShellTask`1.ExecuteNormally(CancellationToken cancellationToken) in
C:\__w\1\s\src\PowerShellEditorServices\Services\PowerShell\Execution\SynchronousPowerShellTask.cs:line 136Environment data
PS E:\pwsh-modules> Get-Module Microsoft.PowerShell.PSResourceGet; $PSVersionTable
ModuleType Version PreRelease Name ExportedCommands
---------- ------- ---------- ---- ----------------
Binary 1.1.1 Microsoft.PowerShell.PSResourceGet {Compress-PSResource, Find-PSResource, Get-InstalledPSResource, Get-PSResourceRepository…}
Key : PSVersion
Value : 7.5.4
Name : PSVersion
Key : PSEdition
Value : Core
Name : PSEdition
Key : GitCommitId
Value : 7.5.4
Name : GitCommitId
Key : OS
Value : Microsoft Windows 10.0.26200
Name : OS
Key : Platform
Value : Win32NT
Name : Platform
Key : PSCompatibleVersions
Value : {1.0, 2.0, 3.0, 4.0…}
Name : PSCompatibleVersions
Key : PSRemotingProtocolVersion
Value : 2.3
Name : PSRemotingProtocolVersion
Key : SerializationVersion
Value : 1.1.0.1
Name : SerializationVersion
Key : WSManStackVersion
Value : 3.0
Name : WSManStackVersionVisuals
No response