Skip to content

Install of 1.17.0 fails to install because of catalog signature mismatch #1014

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
rkeithhill opened this issue Jun 5, 2018 · 4 comments
Closed
Assignees
Milestone

Comments

@rkeithhill
Copy link
Contributor

Before submitting a bug report:

  • Make sure you are able to repro it on the latest released version
  • Perform a quick search for existing issues to check if this bug has already been reported

Steps to reproduce

From PS Core 6.1 Preview 2:

Install-Module PSScriptAnalyzer -Scope CurrentUser

Expected behavior

It just works!

Actual behavior

It fails with this error msg:

PackageManagement\Install-Package : The module 'PSScriptAnalyzer' cannot be installed because the catalog signature in '
PSScriptAnalyzer.cat' does not match the hash generated from the module.
At C:\program files\powershell\6-preview\Modules\PowerShellGet\1.6.0\PSModule.psm1:2057 char:21
+ ...          $null = PackageManagement\Install-Package @PSBoundParameters
+                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo          : InvalidOperation: (Microsoft.Power....InstallPackage:InstallPackage) [Install-Package], Exception
+ FullyQualifiedErrorId : InvalidCatalogSignature,ValidateAndGet-AuthenticodeSignature,Microsoft.PowerShell.PackageManagement.Cmdlets.InstallPackage

After all this time, maybe PowerShellGet / PackageManagement should just punt on this catalog signing feature because NOBODY can seem to publish their modules correctly - including Microsoft.

Now I know that I can use -SkipPublisherCheck to make the install work but this is a lousy user experience as I try to get folks to install from the PSGallery.

Environment data

> $PSVersionTable
Name                           Value
----                           -----
PSVersion                      6.1.0-preview.2
PSEdition                      Core
GitCommitId                    v6.1.0-preview.2
OS                             Microsoft Windows 10.0.17134
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
WSManStackVersion              3.0

> (Get-Module -ListAvailable PSScriptAnalyzer).Version | ForEach-Object { $_.ToString() }
1.17.0
@edyoung
Copy link
Contributor

edyoung commented Jun 5, 2018

I have unlisted version 1.17 from the gallery pending a fix, so users will pick up the previous build instead.

@bergmeister
Copy link
Collaborator

bergmeister commented Jun 5, 2018

There is current work on it and it seems there will be a patched version 1.17.1 to also include a code fix.

@rkeithhill
Copy link
Contributor Author

rkeithhill commented Jun 5, 2018

@edyoung Is there any way to prevent modules from being published that have this problem - catalog sig mismatch? UPDATE: nevermind, I saw your response to my issue in the PowerShellGet project.

@bergmeister
Copy link
Collaborator

1.17.1 has been release (and tested) now to the PSGallery here
Before publishing we tested it using Test-FileCatalog

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants