package name encoding for space in sdc-getpackage sdc-createmachine #9

Closed
kevpie opened this Issue Oct 14, 2011 · 1 comment

Projects

None yet

2 participants

kevpie commented Oct 14, 2011

The package names returned by sdc-listpackages are unusable due to the spaces.

The package name needs to be urlencoded for scd-getpackage to work.

$ sdc-getpackage "Small 1GB"
Maximum number of retries exceeded: 4

$ scd-getpackage Small+1GB
{
"name": "Small 1GB",
"memory": 1024,
"disk": 30720,
"swap": 2048,
"default": false
}

or

$ scd-getpackage Small%201GB
{
"name": "Small 1GB",
"memory": 1024,
"disk": 30720,
"swap": 2048,
"default": false
}

scd-createmachine does not work with any of the following values for --package

  • "Small 1GB"
  • Small+1GB
  • Small%201GB
  • regular_1024
  • Small\ 1GB

A space returns "Invalid request parameters"
Any other character returns "Small+1GB is an invalid package" substituting the joining charcter

The API Doc will need to be update as well.

Contributor
mcavage commented Nov 9, 2011

Hi,

Sorry for the lag on this - anyway, the client is fixed, and you are correct that the docs need to be updated as well. It's in npm as 6.5.0-1.

@mcavage mcavage closed this Nov 9, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment