Open sba923 opened 4 years ago
Can't reproduce it. Exactly what version of PackageManagement and PowerShellGet are you using?
PS 7.0.0-preview.3 C:/Users/steph> (get-module PackageManagement).version.Tostring()
1.4.3
PS 7.0.0-preview.3 C:/Users/steph> (get-module PowerShellGet).version.tostring()
2.2
Alright, updated to just those versions and tried again: Still works without issues :( Does installing the PSFramework directly work for you?
Install-Module PSFramework -Force
Nope....
PS 7.0.0-preview.3 C:/Windows/System32> Install-Module PSFramework -Force -verbose VERBOSE: Acquiring providers for assembly: C:\program files\powershell\7-preview\Modules\PackageManagement\coreclr\netstandard2.0\Microsoft.PackageManagement.ArchiverProviders.dll VERBOSE: Acquiring providers for assembly: C:\program files\powershell\7-preview\Modules\PackageManagement\coreclr\netstandard2.0\Microsoft.PackageManagement.MetaProvider.PowerShell.dll VERBOSE: Acquiring providers for assembly: C:\program files\powershell\7-preview\Modules\PackageManagement\coreclr\netstandard2.0\Microsoft.PackageManagement.CoreProviders.dll VERBOSE: Acquiring providers for assembly: C:\program files\powershell\7-preview\Modules\PackageManagement\coreclr\netstandard2.0\Microsoft.PackageManagement.NuGetProvider.dll VERBOSE: Using the provider 'PowerShellGet' for searching packages. VERBOSE: The -Repository parameter was not specified. PowerShellGet will use all of the registered repositories. VERBOSE: Getting the provider object for the PackageManagement Provider 'NuGet'. VERBOSE: The specified Location is 'https://www.poshtestgallery.com/api/v2/' and PackageManagementProvider is 'NuGet'. VERBOSE: Searching repository 'https://www.poshtestgallery.com/api/v2/FindPackagesById()?id='PSFramework'' for ''. VERBOSE: Total package yield:'0' for the specified package 'PSFramework'.
VERBOSE: Getting the provider object for the PackageManagement Provider 'NuGet'.
VERBOSE: The specified Location is 'https://www.powershellgallery.com/api/v2/' and PackageManagementProvider is 'NuGet'.
VERBOSE: Searching repository 'https://www.powershellgallery.com/api/v2/FindPackagesById()?id='PSFramework'' for ''.
VERBOSE: Total package yield:'1' for the specified package 'PSFramework'.
VERBOSE: Performing the operation "Install-Module" on target "Version '1.0.35' of module 'PSFramework'".
VERBOSE: The installation scope is specified to be 'CurrentUser'.
VERBOSE: The specified module will be installed in 'C:\Users\steph\OneDrive\Documents\PowerShell\Modules'.
VERBOSE: The specified Location is 'NuGet' and PackageManagementProvider is 'NuGet'.
VERBOSE: Downloading module 'PSFramework' with version '1.0.35' from the repository 'https://www.powershellgallery.com/api/v2/'.
VERBOSE: Searching repository 'https://www.powershellgallery.com/api/v2/FindPackagesById()?id='PSFramework'' for ''.
VERBOSE: InstallPackage' - name='PSFramework', version='1.0.35',destination='C:\Users\steph\AppData\Local\Temp\175639040'
VERBOSE: DownloadPackage' - name='PSFramework', version='1.0.35',destination='C:\Users\steph\AppData\Local\Temp\175639040\PSFramework.1.0.35\PSFramework.1.0.35.nupkg', uri='https://www.powershellgallery.com/api/v2/package/PSFramework/1.0.35'
VERBOSE: Downloading 'https://www.powershellgallery.com/api/v2/package/PSFramework/1.0.35'.
VERBOSE: Completed downloading 'https://www.powershellgallery.com/api/v2/package/PSFramework/1.0.35'.
VERBOSE: Completed downloading 'PSFramework'.
VERBOSE: InstallPackageLocal' - name='PSFramework', version='1.0.35',destination='C:\Users\steph\AppData\Local\Temp\175639040'
VERBOSE: Validating the 'PSFramework' module contents under 'C:\Users\steph\AppData\Local\Temp\175639040\PSFramework.1.0.35' path.
VERBOSE: Test-ModuleManifest successfully validated the module manifest file 'C:\Users\steph\AppData\Local\Temp\175639040\PSFramework.1.0.35'.
VERBOSE: Validating the authenticode signature and publisher of the catalog file or module manifest file of the module 'PSFramework'.
VERBOSE: Catalog file 'PSFramework.cat' is not found in the contents of the module 'PSFramework' being installed.
VERBOSE: For publisher validation, current module 'PSFramework' with version '1.0.35' with publisher name '' from root certificate authority ''. Is this module signed by Microsoft: 'False'.
VERBOSE: For publisher validation, using the previously-installed module 'PSFramework' with version '1.0.35' under 'C:\Users\steph\OneDrive\Documents\PowerShell\Modules\PSFramework\1.0.35' with publisher name '' from root certificate authority ''. Is this module signed by Microsoft: 'False'.
VERBOSE: Checking for possible command collisions for the module 'PSFramework' commands.
PackageManagement\Install-Package : Index (zero based) must be greater than or equal to zero and less than the size of the argument list.
At C:\program files\powershell\7-preview\Modules\PowerShellGet\PSModule.psm1:9683 char:34
+ ... talledPackages = PackageManagement\Install-Package @PSBoundParameters
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (Microsoft.PowerShel…lets.InstallPackage:InstallPackage) [Install-Package], Exception
+ FullyQualifiedErrorId : System.FormatException,Microsoft.PowerShell.Commands.RemoveItemCommand,Microsoft.PowerShell.PackageManagement.Cmdlets.InstallPackage
Something related to PSFramework causes
Install-Module FileType
to fail: