The package ID contains invalid characters

Jan 5, 2014 at 5:42 PM
Hello,

I am new to BoxStarter and I am trying to run an installation script from the web. I followed the instructions from the "Launch from the Web" tutorial and I am getting the following error message:
Boxstarter: Installing package 'https://gist.github.com/ClementDagneau/64417c7ac
a92269f2fbc/raw/9e92204d604e2051e1c9c6439a115aad09ac46c9/gistfile1.txt'
Boxstarter Version 2.2.59
(c) 2013 Matt Wrock. http://boxstarter.org

Boxstarter: Disabling Automatic Updates from Windows Update
Calling 'C:\Chocolatey\chocolateyinstall\nuget.exe pack temp_CLÉMENT-PC\temp_CLÉ
MENT-PC.nuspec -NoPackageAnalysis'.
Attempting to build package from 'temp_CL?MENT-PC.nuspec'.
The package ID 'temp_CLÇ%MENT-PC' contains invalid characters. Examples of valid
 package IDs include 'MyPackage' and 'MyPackage.Sample'.
Boxstarter: Created a temporary package temp_CLÉMENT-PC from https://gist.github
.com/ClementDagneau/64417c7aca92269f2fbc/raw/9e92204d604e2051e1c9c6439a115aad09a
c46c9/gistfile1.txt in C:\Users\Clément\AppData\Local\Apps\2.0\DA7H1GZ8.ORH\DNBO
RH5T.B65\boxs..tion_9b0d113b5eadff54_0002.0002_947b8e06a871c9bb\BuildPackages
+ Boxstarter starting Calling Chocolatey to install temp_CLÉMENT-PC. This may ta
ke several minutes to complete...
Chocolatey (v0.9.8.23) is installing 'temp_CLÉMENT-PC' and dependencies. By inst
alling you accept the license for 'temp_CLÉMENT-PC' and each dependency you are
installing.
Unable to find package 'temp_CLÉMENT-PC'.

Command 'install' failed (sometimes this indicates a partial failure). Additiona
l info/packages: temp_CLÉMENT-PC
+ Boxstarter finished Calling Chocolatey to install temp_CLÉMENT-PC. This may ta
ke several minutes to complete... 00:00:05.0845985
Boxstarter: Enabling Automatic Updates from Windows Update
Type ENTER to exit:
The code seems to be trying to build a package name using my username and then fails because that name contains invalid characters. It kind of make sense because my username contains an accent (the username is "Clément").

Is there a known issue/limitation with package names containing accented characters? Or maybe I am doing something wrong somewhere else.

Thank you
Clem
Coordinator
Jan 5, 2014 at 6:19 PM
Hmm. It actually creates the package name based on ComputerName but its basically the same issue with the accented E. I'll need to add some more logic around the package name generation. I had incorrectly assumed that a computer name could not contain these characters. I'll try to get that out in the next release if not sooner. In the mean time there are a couple things you can try:
  1. Change your computername. I realize this may not be a viable option.
  2. Generate the package using New-PackageFromScript (see http://boxstarter.org/CreatingPackages) giving the package a plain name and publish the package to myget or chocolatey (see http://boxstarter.org/PublishingPackages).
Sorry for the inconvenience and thanks very much for reporting this!
Coordinator
Jan 9, 2014 at 3:08 PM
Just pushed a new version that fixes this. Thanks for bringing it up!
Jan 11, 2014 at 9:11 PM
Edited Jan 11, 2014 at 9:17 PM
Thanks a lot for fixing this.

I just tried running the web launcher and I am now getting different error messages. They come from Enable-Remote
Desktop.ps so I took out Enable-RemoteDesktop from the install script and then it worked fine.

I thought I should still bring the error message to your attention. I am happy to start a new discussion if you prefer dealing with one issue per thread.
Boxstarter: Installing package 'https://gist.github.com/mwrock/7382880/raw/f6525
387b4b524b8eccef6ed4d5ec219c82c0ac7/gistfile1.txt'
Boxstarter Version 2.2.78
(c) 2014 Matt Wrock. http://boxstarter.org

Boxstarter: Disabling Automatic Updates from Windows Update
Calling 'C:\Chocolatey\chocolateyinstall\nuget.exe pack temp_BoxstarterPackage\t
emp_BoxstarterPackage.nuspec -NoPackageAnalysis'.
Attempting to build package from 'temp_BoxstarterPackage.nuspec'.
Successfully created package 'C:\Users\Cl?ment\AppData\Local\Apps\2.0\DA7H1GZ8.O
RH\DNBORH5T.B65\boxs..tion_9b0d113b5eadff54_0002.0002_88c98c00ac961a7b\BuildPack
ages\temp_BoxstarterPackage.1.0.0.nupkg'.

Boxstarter: Created a temporary package temp_BoxstarterPackage from https://gist
.github.com/mwrock/7382880/raw/f6525387b4b524b8eccef6ed4d5ec219c82c0ac7/gistfile
1.txt in C:\Users\Clément\AppData\Local\Apps\2.0\DA7H1GZ8.ORH\DNBORH5T.B65\boxs.
.tion_9b0d113b5eadff54_0002.0002_88c98c00ac961a7b\BuildPackages
+ Boxstarter starting Calling Chocolatey to install  temp_BoxstarterPackage. Thi
s may take several minutes to complete...
Chocolatey (v0.9.8.23) is installing ' temp_BoxstarterPackage' and dependencies.
 By installing you accept the license for ' temp_BoxstarterPackage' and each dep
endency you are installing.
______ temp_BoxstarterPackage v1.0.0 ______
Get-WmiObject : Invalid namespace
At C:\Users\Clément\AppData\Local\Apps\2.0\DA7H1GZ8.ORH\DNBORH5T.B65\boxs..tion
_9b0d113b5eadff54_0002.0002_88c98c00ac961a7b\Boxstarter.WinConfig\Enable-Remote
Desktop.ps1:10 char:19
+     (Get-WmiObject <<<<  -Class "Win32_TerminalServiceSetting" -Namespace roo
t\cimv2\terminalservices).SetAllowTsConnections(1) | out-null
    + CategoryInfo          : InvalidOperation: (:) [Get-WmiObject], Managemen
   tException
    + FullyQualifiedErrorId : GetWMIManagementException,Microsoft.PowerShell.C
   ommands.GetWmiObjectCommand

Write-Error : Package 'temp_BoxstarterPackage v1.0.0' did not install successfu
lly: You cannot call a method on a null-valued expression.
At C:\Chocolatey\chocolateyinstall\functions\Chocolatey-NuGet.ps1:90 char:28
+                 Write-Error <<<<  "Package `'$installedPackageName v$installe
dPackageVersion`' did not install successfully: $($_.Exception.Message)"
    + CategoryInfo          : NotSpecified: (:) [Write-Error], WriteErrorExcep
   tion
    + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorExceptio
   n,Write-Error

Finished installing ' temp_BoxstarterPackage' and dependencies - if errors not s
hown in console, none detected. Check log for errors if unsure.
+ Boxstarter finished Calling Chocolatey to install  temp_BoxstarterPackage. Thi
s may take several minutes to complete... 00:00:04.4224822
Boxstarter: Enabling Automatic Updates from Windows Update
Type ENTER to exit:
Coordinator
Jan 11, 2014 at 10:23 PM
Cool. Glad to know thats fixed and thanks for reporting the Remote Desktop Issue! Out of curiosity, what OS version are you using?
Jan 12, 2014 at 1:41 PM
OS Name: Microsoft Windows 7 Home Premium
OS Version: 6.1.7601 Service Pack 1 Build 7601