Cannot install module because it is not a properly-formed module #453
Unanswered
grzegorzwierzbicki
asked this question in
General
Replies: 2 comments 9 replies
-
Small update: the issue is NOT occurring when using PowerShell 7.0.6 |
Beta Was this translation helpful? Give feedback.
0 replies
-
This message makes me think it might be a transient error: |
Beta Was this translation helpful? Give feedback.
9 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi
I am trying to install the module on a Windows 2012 R2 server and run into this issue.
Install-Module pnp.powershell -Scope AllUsers -AcceptLicense -Verbose
VERBOSE: Acquiring providers for assembly: C:\Program Files\WindowsPowerShell\Modules\PackageManagement\fullclr\Microsoft.PackageManagement.ArchiverProviders.dll
VERBOSE: Acquiring providers for assembly: C:\Program Files\WindowsPowerShell\Modules\PackageManagement\fullclr\Microsoft.PackageManagement.MetaProvider.PowerShell.dll
VERBOSE: Acquiring providers for assembly: C:\Program Files\WindowsPowerShell\Modules\PackageManagement\fullclr\Microsoft.PackageManagement.NuGetProvider.dll
VERBOSE: Acquiring providers for assembly: C:\Program Files\WindowsPowerShell\Modules\PackageManagement\fullclr\Microsoft.PackageManagement.CoreProviders.dll
VERBOSE: Acquiring providers for assembly: C:\Program Files\WindowsPowerShell\Modules\PackageManagement\fullclr\Microsoft.PackageManagement.MsuProvider.dll
VERBOSE: Acquiring providers for assembly: C:\Program Files\WindowsPowerShell\Modules\PackageManagement\fullclr\Microsoft.PackageManagement.MsiProvider.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.powershellgallery.com/api/v2' and PackageManagementProvider is 'NuGet'.
VERBOSE: Searching repository 'https://www.powershellgallery.com/api/v2/FindPackagesById()?id='pnp.powershell'' for ''.
VERBOSE: Total package yield:'1' for the specified package 'pnp.powershell'.
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='pnp.powershell'' for ''.
VERBOSE: Total package yield:'0' for the specified package 'pnp.powershell'.
VERBOSE: Performing the operation "Install-Module" on target "Version '1.4.0' of module 'PnP.PowerShell'".
VERBOSE: The installation scope is specified to be 'AllUsers'.
VERBOSE: The specified module will be installed in 'C:\Program Files\WindowsPowerShell\Modules'.
VERBOSE: The specified Location is 'NuGet' and PackageManagementProvider is 'NuGet'.
VERBOSE: Downloading module 'PnP.PowerShell' with version '1.4.0' from the repository 'https://www.powershellgallery.com/api/v2'.
VERBOSE: Searching repository 'https://www.powershellgallery.com/api/v2/FindPackagesById()?id='PnP.PowerShell'' for ''.
VERBOSE: InstallPackage' - name='PnP.PowerShell', version='1.4.0',destination='C:\Users\xxxxxxxxx\AppData\Local\Temp\2053916661'
VERBOSE: DownloadPackage' - name='PnP.PowerShell',version='1.4.0',destination='C:\Users\xxxxxxxxx\AppData\Local\Temp\2053916661\PnP.PowerShell.1.4.0\PnP.PowerShell.1.4.0.nupkg',uri='https://www.powershellgallery.com/api/v2/package/PnP.PowerShell/1.4.0'
VERBOSE: Downloading 'https://www.powershellgallery.com/api/v2/package/PnP.PowerShell/1.4.0'.
VERBOSE: Completed downloading 'https://www.powershellgallery.com/api/v2/package/PnP.PowerShell/1.4.0'.
VERBOSE: Completed downloading 'PnP.PowerShell'.
VERBOSE: Hash for package 'PnP.PowerShell' does not match hash provided from the server.
VERBOSE: InstallPackageLocal' - name='PnP.PowerShell', version='1.4.0',destination='C:\Users\xxxxxxxxx\AppData\Local\Temp\2053916661'
VERBOSE: Validating the 'PnP.PowerShell' module contents under 'C:\Users\xxxxxxxxx\AppData\Local\Temp\2053916661\PnP.PowerShell.1.4.0' path.
PackageManagement\Install-Package : The module 'PnP.PowerShell' cannot be installed or updated because it is not a properly-formed module.
At C:\Program Files\WindowsPowerShell\Modules\PowerShellGet\PSModule.psm1:9711 char:34
+ $installedPackages = PackageManagement\Install-Package @PSBoundParam ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (Microsoft.Power....InstallPackage:InstallPackage) [Install-Package], Exception
+ FullyQualifiedErrorId : InvalidManifestModule,Test-ValidManifestModule,Microsoft.PowerShell.PackageManagement.Cmdlets.InstallPackage
Beta Was this translation helpful? Give feedback.
All reactions