-
Notifications
You must be signed in to change notification settings - Fork 100
Closed
Labels
Description
Prerequisites
- Write a descriptive title.
- Make sure you are able to repro it on the latest released version
- Search the existing issues.
- Refer to the FAQ.
- Refer to Differences between Windows PowerShell 5.1 and PowerShell.
Steps to reproduce
Hello,
I'm currently using pwsh in my wsl instance (Ubuntu 20.04).
I already tried updating powershell, powershellget, etc... Uninstalling/reinstalling...
I was thinking it was related to tls, so I used the following command:
[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.SecurityProtocolType]::Tls12But nothing worked so far.
When I use Invoke-Webrequest to call the artifactory endpoint, everything is ok, even when setting the -SslProtocol to tls12, I don't understand what's the issue here.
I checked the documentation, stackoverflow, reddit, but I always find windows related issues, not so much about linux issues with this.
Thanks for your work/support,
Diliz
Expected behavior
Install-Module my.module
Module installed!Actual behavior
Install-Module my.module
WARNING: Unable to resolve package source 'https://my-artifactory.com/api/nuget/my-nugget-repo'.
Install-Package: No match was found for the specified search criteria and module name 'my.module'. Try Get-PSRepository to see all available registered module repositories.Error details
DEBUG: 00:00:00.0000003 Calling New() : MethodName = 'ResolvePackageSources'
DEBUG: 00:00:00.0001204 Name: myrepo
DEBUG: 00:00:00.0001488 ErrorVariable: ev
DEBUG: 00:00:00.0001711 Verbose: False
DEBUG: 00:00:00.0013760 INVOKING PowerShell Fn Resolve-PackageSource with args that has length 0
DEBUG: 00:00:00.0071198 In PowerShellGet Provider - 'Resolve-PackageSource'.
DEBUG: 00:00:00.0525186 Yielding package source for myrepo at location https://my-artifactory.com/api/nuget/my-nugget-repo
DEBUG: 00:00:00.0568927 Done calling powershell «Resolve-PackageSource» «PSModule»
DEBUG: 00:00:00.0611399 Calling New() : MethodName = 'GetDynamicOptions'
DEBUG: 00:00:00.0611556 Name: myrepo
DEBUG: 00:00:00.0611624 ErrorVariable: ev
DEBUG: 00:00:00.0611695 Verbose: False
DEBUG: 00:00:00.0618234 INVOKING PowerShell Fn Get-DynamicOptions with args Provider that has length 1
DEBUG: 00:00:00.0624285 In PowerShellGet Provider - 'Get-DynamicOptions'.
DEBUG: 00:00:00.0637846 Done calling powershell «Get-DynamicOptions» «PSModule»
DEBUG: 00:00:00.0672374 Calling New() : MethodName = 'GetDynamicOptions'
DEBUG: 00:00:00.0672560 Name: myrepo
DEBUG: 00:00:00.0672633 ErrorVariable: ev
DEBUG: 00:00:00.0672706 Verbose: False
DEBUG: 00:00:00.0681014 INVOKING PowerShell Fn Get-DynamicOptions with args Source that has length 1
DEBUG: 00:00:00.0688727 In PowerShellGet Provider - 'Get-DynamicOptions'.
DEBUG: 00:00:00.0729550 Done calling powershell «Get-DynamicOptions» «PSModule»
DEBUG: 00:00:00.0842842 Calling New() : MethodName = 'ResolvePackageSources'
DEBUG: 00:00:00.0847399 Name: myrepo
DEBUG: 00:00:00.0850854 ProviderName: PowerShellGet
DEBUG: 00:00:00.0857262 MessageResolver: Microsoft.PowerShell.PackageManagement.Cmdlets.GetMessageString
DEBUG: 00:00:00.0863698 ErrorVariable: ev
DEBUG: 00:00:00.0868930 Verbose: False
DEBUG: 00:00:00.0887378 INVOKING PowerShell Fn Resolve-PackageSource with args that has length 0
DEBUG: 00:00:00.0897178 In PowerShellGet Provider - 'Resolve-PackageSource'.
DEBUG: 00:00:00.1009525 Yielding package source for myrepo at location https://my-artifactory.com/api/nuget/my-nugget-repo
DEBUG: 00:00:00.1029254 Done calling powershell «Resolve-PackageSource» «PSModule»
DEBUG: 00:00:00.1072713 Calling New() : MethodName = 'ResolvePackageSources'
DEBUG: 00:00:00.1077630 Name: myrepo
DEBUG: 00:00:00.1081932 ProviderName: PowerShellGet
DEBUG: 00:00:00.1086130 MessageResolver: Microsoft.PowerShell.PackageManagement.Cmdlets.GetMessageString
DEBUG: 00:00:00.1090289 ErrorVariable: ev
DEBUG: 00:00:00.1093783 Verbose: False
DEBUG: 00:00:00.1108112 INVOKING PowerShell Fn Resolve-PackageSource with args that has length 0
DEBUG: 00:00:00.1119740 In PowerShellGet Provider - 'Resolve-PackageSource'.
DEBUG: 00:00:00.1152584 Yielding package source for myrepo at location https://my-artifactory.com/api/nuget/my-nugget-repo
DEBUG: 00:00:00.1165763 Done calling powershell «Resolve-PackageSource» «PSModule»
DEBUG: 00:00:00 Calling New() : MethodName = 'ResolvePackageSources'
DEBUG: 00:00:00.0000234 Verbose: True
DEBUG: 00:00:00.0000316 Credential: System.Management.Automation.PSCredential
DEBUG: 00:00:00.0000383 Name: my.module
DEBUG: 00:00:00.0000450 Source: myrepo
DEBUG: 00:00:00.0000512 Debug: True
DEBUG: 00:00:00.0007644 INVOKING PowerShell Fn Resolve-PackageSource with args that has length 0
DEBUG: 00:00:00.0013593 In PowerShellGet Provider - 'Resolve-PackageSource'.
DEBUG: 00:00:00.0033698 Yielding package source for myrepo at location https://my-artifactory.com/api/nuget/my-nugget-repo
DEBUG: 00:00:00.0042707 Done calling powershell «Resolve-PackageSource» «PSModule»
DEBUG: 00:00:00.0070424 Calling New() : MethodName = 'GetDynamicOptions'
DEBUG: 00:00:00.0070609 Verbose: True
DEBUG: 00:00:00.0070682 Credential: System.Management.Automation.PSCredential
DEBUG: 00:00:00.0070754 Name: my.module
DEBUG: 00:00:00.0070816 Source: myrepo
DEBUG: 00:00:00.0070882 Debug: True
DEBUG: 00:00:00.0080318 INVOKING PowerShell Fn Get-DynamicOptions with args Provider that has length 1
DEBUG: 00:00:00.0089294 In PowerShellGet Provider - 'Get-DynamicOptions'.
DEBUG: 00:00:00.0106245 Done calling powershell «Get-DynamicOptions» «PSModule»
DEBUG: 00:00:00.0133953 Calling New() : MethodName = 'GetDynamicOptions'
DEBUG: 00:00:00.0134189 Verbose: True
DEBUG: 00:00:00.0134286 Credential: System.Management.Automation.PSCredential
DEBUG: 00:00:00.0134353 Name: my.module
DEBUG: 00:00:00.0134424 Source: myrepo
DEBUG: 00:00:00.0134486 Debug: True
DEBUG: 00:00:00.0148395 INVOKING PowerShell Fn Get-DynamicOptions with args Source that has length 1
DEBUG: 00:00:00.0160872 In PowerShellGet Provider - 'Get-DynamicOptions'.
DEBUG: 00:00:00.0190927 Done calling powershell «Get-DynamicOptions» «PSModule»
DEBUG: 00:00:00.0267790 Calling New() : MethodName = 'GetDynamicOptions'
DEBUG: 00:00:00.0268143 Verbose: True
DEBUG: 00:00:00.0268216 Credential: System.Management.Automation.PSCredential
DEBUG: 00:00:00.0268294 Name: my.module
DEBUG: 00:00:00.0268362 Source: myrepo
DEBUG: 00:00:00.0268575 Debug: True
DEBUG: 00:00:00.0281315 INVOKING PowerShell Fn Get-DynamicOptions with args Package that has length 1
DEBUG: 00:00:00.0289324 In PowerShellGet Provider - 'Get-DynamicOptions'.
DEBUG: 00:00:00.0346017 Done calling powershell «Get-DynamicOptions» «PSModule»
DEBUG: 00:00:00.0381408 Calling New() : MethodName = 'GetDynamicOptions'
DEBUG: 00:00:00.0381654 Verbose: True
DEBUG: 00:00:00.0381888 Credential: System.Management.Automation.PSCredential
DEBUG: 00:00:00.0382000 Name: my.module
DEBUG: 00:00:00.0382067 Source: myrepo
DEBUG: 00:00:00.0382310 Debug: True
DEBUG: 00:00:00.0395876 INVOKING PowerShell Fn Get-DynamicOptions with args Install that has length 1
DEBUG: 00:00:00.0403800 In PowerShellGet Provider - 'Get-DynamicOptions'.
DEBUG: 00:00:00.0495403 Done calling powershell «Get-DynamicOptions» «PSModule»
DEBUG: 00:00:00.0570786 Calling New() : MethodName = 'ResolvePackageSources'
DEBUG: 00:00:00.0577056 Debug: True
DEBUG: 00:00:00.0582803 Type: Module
DEBUG: 00:00:00.0587746 Name: my.module
DEBUG: 00:00:00.0593710 Credential: System.Management.Automation.PSCredential
DEBUG: 00:00:00.0600378 MessageResolver: Microsoft.PowerShell.PackageManagement.Cmdlets.GetMessageString
DEBUG: 00:00:00.0609529 Scope: CurrentUser
DEBUG: 00:00:00.0615602 Verbose: True
DEBUG: 00:00:00.0621031 ProviderName: PowerShellGet
DEBUG: 00:00:00.0631093 Source: myrepo
DEBUG: 00:00:00.0651247 INVOKING PowerShell Fn Resolve-PackageSource with args that has length 0
DEBUG: 00:00:00.0666850 In PowerShellGet Provider - 'Resolve-PackageSource'.
VERBOSE: Repository details, Name = 'myrepo', Location = 'https://my-artifactory.com/api/nuget/my-nugget-repo'; IsTrusted = 'True'; IsRegistered = 'True'.
DEBUG: 00:00:00.0708318 Yielding package source for myrepo at location https://my-artifactory.com/api/nuget/my-nugget-repo
DEBUG: 00:00:00.0725405 Done calling powershell «Resolve-PackageSource» «PSModule»
DEBUG: 00:00:00.0728493 Calling SearchForPackages. Name='my.module'
VERBOSE: Using the provider 'PowerShellGet' for searching packages.
DEBUG: 00:00:00.0738030 PackageProvider::FindPackage with name my.module
DEBUG: 00:00:00.0741931 Calling SearchForPackages After Select 1
DEBUG: 00:00:00.0785278 Calling New() : MethodName = 'FindPackage'
DEBUG: 00:00:00.0794427 Debug: True
DEBUG: 00:00:00.0803038 Type: Module
DEBUG: 00:00:00.0813336 Name: my.module
DEBUG: 00:00:00.0821083 Credential: System.Management.Automation.PSCredential
DEBUG: 00:00:00.0827952 MessageResolver: Microsoft.PowerShell.PackageManagement.Cmdlets.GetMessageString
DEBUG: 00:00:00.0833057 Scope: CurrentUser
DEBUG: 00:00:00.0837560 Verbose: True
DEBUG: 00:00:00.0841578 ProviderName: PowerShellGet
DEBUG: 00:00:00.0845100 Source: myrepo
DEBUG: 00:00:00.0855999 INVOKING PowerShell Fn Find-Package with args System.String[], , , that has length 4
DEBUG: 00:00:00.0865549 In PowerShellGet Provider - 'Find-Package'.
DEBUG: 00:00:00.0871903 OPTION: Debug => True
DEBUG: 00:00:00.0878110 OPTION: Type => Module
DEBUG: 00:00:00.0884739 OPTION: Name => my.module
DEBUG: 00:00:00.0895660 OPTION: Credential => System.Management.Automation.PSCredential
DEBUG: 00:00:00.0903590 OPTION: MessageResolver => Microsoft.PowerShell.PackageManagement.Cmdlets.GetMessageString
DEBUG: 00:00:00.0909503 OPTION: Scope => CurrentUser
DEBUG: 00:00:00.0916099 OPTION: Verbose => True
DEBUG: 00:00:00.0922733 OPTION: ProviderName => PowerShellGet
DEBUG: 00:00:00.0930206 OPTION: Source => myrepo
VERBOSE: Using the specified source names : 'myrepo'.
VERBOSE: Getting the provider object for the PackageManagement Provider 'NuGet'.
VERBOSE: The specified Location is 'https://my-artifactory.com/api/nuget/my-nugget-repo' and PackageManagementProvider is 'NuGet'.
DEBUG: 00:00:00.1036587 PackageProvider::FindPackage with name my.module
DEBUG: 00:00:00.1065135 Calling 'NuGet'::'FindPackage' - name='my.module', requiredVersion='',minimumVersion='', maximumVersion='''.
DEBUG: 00:00:00.1072197 Iterating 'my.module'.
DEBUG: 00:00:00.1085439 There are '0' registered sources in 'NuGet' provider.
DEBUG: 00:00:00.1092062 Source 'https://my-artifactory.com/api/nuget/my-nugget-repo' is not one of the registered sources in 'NuGet' provider.
WARNING: Unable to resolve package source 'https://my-artifactory.com/api/nuget/my-nugget-repo'.
VERBOSE: Total package yield:'0' for the specified package 'my.module'.
DEBUG: 00:00:03.2344332 Completed iterating for 'my.module'.
DEBUG: 00:00:03.2351201 PowerShell Script 'PSModule' Function 'Find-Package' returns null.
DEBUG: 00:00:03.2365161 Done calling powershell «Find-Package» «PSModule»
DEBUG: 00:00:03.2371170 unmatched package name='my.module'
Install-Package: No match was found for the specified search criteria and module name 'my.module'. Try
Get-PSRepository to see all available registered module repositories.Environment data
Name Value
---- -----
PSVersion 7.3.0-preview.5
PSEdition Core
GitCommitId 7.3.0-preview.5
OS Linux 5.10.16.3-microsoft-standard-WSL2 PowerShell/PowerShell#1 SMP Fri Apr 2 22:23:49 UTC …
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0Visuals
No response