Coder Social home page Coder Social logo

edge-scs's Introduction

edge-scs

What is it

edge-scs is an extension for edge that allows invoking scriptcs from node.js.

Hello edge-scs

Below is a simple snippet of using scriptcs from edge

var edge = require('edge');
var hello = edge.func('scs', function() {/*
static object Invoke(string s) {
    return s;
}
*/});
hello("Hello from scriptcs", function(error,result) {
    if (error) throw error;
    console.log(result);
});  

edge-scs's People

Contributors

glennblock avatar

Stargazers

 avatar hoangitk avatar smartcaveman avatar Will Anderson avatar  avatar Chris Ray avatar Chris Meagher avatar Brad Jones avatar Indrajit Chakrabarty avatar Rick Beerendonk avatar Doug Finke avatar Mattias Karlsson avatar

Watchers

Brad Jones avatar Doug Finke avatar Rick Beerendonk avatar James Cloos avatar Mattias Karlsson avatar Chris Ray avatar

edge-scs's Issues

Autofac.Configuration.dll is 'blocked'

Since there is no npm module, I just dropped the built code straight into node_modules. Running a simple example doesn't work right away, it spits out this nasty message:

System.TypeInitializationException: The type initializer for 'EdgeCompiler' threw an exception. ---> System.NotSupportedException: An attempt was made to load an assembly from a network location which would have caused the assembly to be sandboxed in previous versions of the .NET Framework. This release of the .NET Framework does not enable CAS policy by default, so this load may be dangerous. If this load is not intended to sandbox the assembly, please enable the loadFromRemoteSources switch. See http://go.microsoft.com/fwlink/?LinkId=155569 for more information.
   at System.Reflection.RuntimeAssembly.nLoadFile(String path, Evidence evidence)
   at System.Reflection.Assembly.LoadFile(String path)
   at EdgeCompiler..cctor()
   --- End of inner exception stack trace ---
   at EdgeCompiler..ctor()
   --- End of inner exception stack trace ---
   at System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandleInternal& ctor, Boolean& bNeedSecurityCheck)
   at System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache, StackCrawlMark& stackMark)
   at System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache, StackCrawlMark& stackMark)
   at System.Activator.CreateInstance(Type type, Boolean nonPublic)
   at ClrFunc.Initialize(Handle<v8::Value>* , Arguments* args)

Which basically says that one or more of the assemblies being loaded is "blocked" and needs to be unblocked. I found that the "Autofac.Configuration.dll" seemed to be the only blocked assembly. Unblocked it and everything started to work.

Publish to npm

If everything goes well with upgrading to use 0.10.2, the next step is npm publish :-)

Support for mono

I just tried the latest scriptcs on linux/mono and it works, but the edge-scs bridge appears to be pre-mono scriptcs support.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.