Skip to content
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

(visualstudiocode) Get-PackageParameters is not recognized when installing using Install-Package #551

Closed
jbolduan opened this issue Jan 30, 2017 · 2 comments
Labels
invalid This is used to mark Hacktoberfest PR's as invalid

Comments

@jbolduan
Copy link

While PackageManagement believe's it's installed VisualStudioCode 1.8.1 it's not actually completing and it appears to be failing on one of the Chocolatey core extensions for some reason. Below is the command line I was using as well as the output of the verbose/debug logs.

Installing using the command line:

Install-Package -ProviderName "Chocolatey" -Name "VisualStudioCode" -Force -Verbose -Debug

I get the following output from the console when running this command.

00:00:00 Calling 'Chocolatey::GetDynamicOptions' 'Provider'
00:00:00.0028342 Calling 'Chocolatey::GetDynamicOptions' 'Source'
00:00:00.0076760 Calling 'Chocolatey::GetDynamicOptions' 'Package'
00:00:00.0139028 Calling 'Chocolatey::GetDynamicOptions' 'Install'
00:00:01.1522057 Calling SearchForPackages. Name='VisualStudioCode'
Using the provider 'Chocolatey' for searching packages.
00:00:01.1532573 PackageProvider::FindPackage with name VisualStudioCode
00:00:01.1536117 Calling SearchForPackages After Select 1
00:00:01.1555751 Calling 'Chocolatey::FindPackage' 'VisualStudioCode','','','','0'
00:00:01.1556174 Iterating
00:00:01.1883347 Yielding
00:00:01.1886588 Done Iterating
00:00:01.1930389 Calling 'Chocolatey::GetInstalledPackages' 'VisualStudioCode','1.8.1','',''
00:00:01.9540245 Calling 'Chocolatey::InstallPackage' 
'$aHR0cDovL2Nob2NvbGF0ZXkub3JnL2FwaS92Mi8=\VmlzdWFsU3R1ZGlvQ29kZQ==\MS44LjE=\'
NuGet: Attempting to resolve dependency 'chocolatey-core.extension (≥ 1.0.4)'.
NuGet: Attempting to resolve dependency 'DotNet4.5.2'.
NuGet: Installing 'visualstudiocode 1.8.1'.
NuGet: Successfully installed 'visualstudiocode 1.8.1'.
Exception : DefaultDomain//CommandNotFoundException/The term 'Get-PackageParameters' is not recognized as the name of 
a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, 
verify that the path is correct and try again.
   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(IEnumerable input, PSInvocationSettings settings)
   at Microsoft.PackageManagement.ChocolateyPrototype.ChocolateyRequest.Invoke(String script)
   at Microsoft.PackageManagement.ChocolateyPrototype.ChocolateyRequest.InvokeChocolateyScript(String path, String 
workingDirectory)

Name                           Version          Source           Summary                                               
----                           -------          ------           -------                                               
VisualStudioCode               1.8.1            chocolatey       Visual Studio Code

I've confirmed that I have the chocolatey-core.extension.1.0.5 installed (or at least the folder shows up in C:\Chocolatey\lib. Previous versions of this installer have worked through the PackageManagement module but it doesn't appear to work any longer. If you need additional information let me know.

@AdmiringWorm
Copy link
Member

I wonder if maybe the powershell PackageManagement don't support importing chocolatey extensions (I'm almost sure I read somewhere that the provider used is using several years old code).
Have you tried installing it directly with choco install visualstudiocode?

I don't really have any experience when it comes to the Install-Module cmdlet, so let me reference some people that may help on this.

/cc @ferventcoder @gep13 @pascalberger

@ferventcoder
Copy link
Contributor

It doesn't - please use choco until you hear otherwise. Follow this thread - chocolatey-community/chocolatey-oneget#5

@ferventcoder ferventcoder added invalid This is used to mark Hacktoberfest PR's as invalid and removed 0 - _Triaging labels Jan 30, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
invalid This is used to mark Hacktoberfest PR's as invalid
Projects
None yet
Development

No branches or pull requests

3 participants