Skip to content
This repository has been archived by the owner on Dec 18, 2017. It is now read-only.

Parsing arrays in scripts section #659

Closed
rustd opened this issue Sep 24, 2014 · 0 comments
Closed

Parsing arrays in scripts section #659

rustd opened this issue Sep 24, 2014 · 0 comments

Comments

@rustd
Copy link

rustd commented Sep 24, 2014

If you have the following section with arrays then we throw an error. This is what the templates will have so we should fix it.

    "scripts": {
 "prepack": ["npm install","bower install", "grunt"]

    }

Exception details
Error 1 System.ArgumentException: Can not convert Array to String.
at Newtonsoft.Json.Linq.JToken.op_Explicit(JToken value)
at Newtonsoft.Json.Linq.JToken.ToObject(Type objectType)
at Newtonsoft.Json.Linq.JToken.ToObjectT
at Microsoft.Framework.Runtime.Project.GetProject(String json, String projectName, String projectPath)
at Microsoft.Framework.Runtime.Project.TryGetProject(String path, Project& project)
at Microsoft.Framework.Runtime.ApplicationHostContext.get_Project()
at Microsoft.Framework.Runtime.ApplicationHostContext..ctor(IServiceProvider serviceProvider, String projectDirectory, String packagesDirectory, String configuration, FrameworkName targetFramework, ICache cache, ICacheContextAccessor cacheContextAccessor)
at Microsoft.Framework.DesignTimeHost.ApplicationContext.Initialize(String appPath, FrameworkName targetFramework, String configuration)
at Microsoft.Framework.DesignTimeHost.ApplicationContext.Calculate()
at Microsoft.Framework.DesignTimeHost.ApplicationContext.DoProcessLoop()
at Microsoft.Framework.DesignTimeHost.ApplicationContext.ProcessLoop(Object state) 0 0 WebApplication74

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

No branches or pull requests

3 participants