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

Error in 'wu list' #47

Closed
wukefe opened this issue Feb 17, 2016 · 5 comments
Closed

Error in 'wu list' #47

wukefe opened this issue Feb 17, 2016 · 5 comments

Comments

@wukefe
Copy link
Contributor

wukefe commented Feb 17, 2016

Before I check the command 'wu list' in the directory of 'Ostrich2', I have followed the steps below.

  1. Sync wu-wei-benchmarking-toolkit, and update the executable file 'wu'
  2. Sync Ostrich2

The error message is pasted here.

(Canopy 64bit) HF:Ostrich2 wu list
fs.js:844
  return binding.stat(pathModule._makeLong(path));
                 ^

Error: ENOENT: no such file or directory, stat '/Users/wukefe/Documents/GitHub/wu/Ostrich2/.wu/setup.json'
    at Error (native)
    at Object.fs.statSync (fs.js:844:18)
    at Object.<anonymous> (/Users/wukefe/Documents/GitHub/wu-wei-benchmark-toolkit/bin/list:39:8)
    at Module._compile (module.js:410:26)
    at Object.Module._extensions..js (module.js:417:10)
    at Module.load (module.js:344:32)
    at Function.Module._load (module.js:301:12)
    at Function.Module.runMain (module.js:442:10)
    at startup (node.js:136:18)
    at node.js:966:3
@wukefe wukefe added the bug label Feb 17, 2016
@elavoie
Copy link
Member

elavoie commented Feb 17, 2016

Do you have a 'setup.json' file in your .wu directory at the root of your Ostrich2 repository?

It should look like:

{
    "platform": "mba-2011"
}

@wukefe
Copy link
Contributor Author

wukefe commented Feb 17, 2016

You are right. Because I deleted the old repository and forked the latest one, the setup.json is missing.

After I add it into the .wu directory, the message returned from 'wu list' seems incorrect. What does 'no (or more than one) schemas match' mean?

(Canopy 64bit) HF:.wu wu list
[
  {
    "field": "data",
    "message": "no (or more than one) schemas match",
    "value": {
      "type": "platform",
      "short-name": "Hanfeng’s MacBook Pro",
      "name": "Darwin-15.3.0-x86_64-i386-64bit",
      "cpu": "Intel Core i5",
      "gpu": "Intel Iris Graphics 6100",
      "memory": "8 GB",
      "os": "Mac OS X 10.11.3",
      "supported-languages": [
        "x86_64"
      ],
      "supported-formats": []
    }
  }
]

@elavoie
Copy link
Member

elavoie commented Feb 17, 2016

The message means that the JSON description listed in the value field does not conform to an expected schema. In your case, the short name you are using uses non-supported characters such as the apostrophe (') and spaces (' '). Look at the regexp for 'short-name' in the schema file to see what is valid:
https://github.com/Sable/wu-wei-benchmarking-toolkit/blob/master/lib/config-schema.json

Also, while the toolkit will not reject it for that, try to use really short names for the 'short-name' field so that it does not require a lot of typing when using it. I would suggest 'hf-mbp' rather than 'Hanfeng's MacBook Pro'. The commandline interace requires the user to type the short-name in an exact way to refer to the whole description. Ex: If we were to filter all runs according to the platform their where obtain from, it is a lot more convenient to type the second version.

It would be good if your script reflected those constraints in the choice of a short-name. Otherwise we will have to ask people to change them manually.

@elavoie
Copy link
Member

elavoie commented Feb 17, 2016

I added this issue Sable/wu-wei-benchmarking-toolkit#15 to eventually fix it and make it more convenient.

@elavoie elavoie removed the bug label Feb 17, 2016
@elavoie elavoie closed this as completed Feb 17, 2016
@wukefe
Copy link
Contributor Author

wukefe commented Feb 17, 2016

Thanks a lot.

The illegal characters in the field of short-name lead to the error. I also find a new field environments is added into the platform.json. I will modify platform script to generate the new field.

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

No branches or pull requests

2 participants