Skip to content

Proxy Error wrapped Promise #417

Description

@sky-train

Fatal error in runtime\runtime-debug.cc, line 1423

Check failed: args[0]->IsJSObject().

code showing the error

function createProxy(){
    let handler = {
        get(target,key,context){
            return Reflect.get(target,key,context);
        }
    }
    ,data = {a:1};
    return new Proxy(data,handler);
}

function load(){
    return new Promise(function (resolve,reject) {
        let proxy = createProxy();
        resolve(proxy);
    });
}

load().then(function (proxy) {
    console.log(proxy.a);
});

Activity

  1. addaleax commented on Dec 21, 2016

    @addaleax
    Member

    What version of Node.js are you using?

  2. sky-train commented on Dec 21, 2016

    @sky-train
    Author

    Node 7.3.0

  3. addaleax commented on Dec 21, 2016

    @addaleax
    Member

    Just running the code as node script.js does not show any problems. You are probably doing something debug-related here, judging from the file that throws the error.

    Can you share the command you are using?

  4. sky-train commented on Dec 21, 2016

    @sky-train
    Author

    Yes you are right.
    error occurs when it run in WebStrom 2016.1.3 (and VS2015) in debug mode

    Thank you

  5. addaleax commented on Dec 22, 2016

    @addaleax
    Member

    Sorry, I can’t help you right now, but please open an issue at https://github.com/nodejs/node and:

    • Include a link to this issue
    • Include all the information above (Reproducible script + node version + environment)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions