Skip to content

Node.js v6: v8::ObjectTemplate::Set() with non-primitive values is deprecated #758

Closed
@mathiasbynens

Description

@mathiasbynens
$ node --version
v6.0.0

$ node -e 'require("canvas")'
(node) v8::ObjectTemplate::Set() with non-primitive values is deprecated
(node) and will stop working in the next major release.

==== JS stack trace =========================================

Security context: 0x4d535bc9fa9 <JS Object>#0#
    [stack trace omitted]
=====================


==== C stack trace ===============================

 1: v8::Template::Set(v8::Local<v8::Name>, v8::Local<v8::Data>, v8::PropertyAttribute)
 2: Canvas::Initialize(v8::Local<v8::Object>)
 3: init(v8::Local<v8::Object>)
 4: node::DLOpen(v8::FunctionCallbackInfo<v8::Value> const&)
 5: v8::internal::FunctionCallbackArguments::Call(void (*)(v8::FunctionCallbackInfo<v8::Value> const&))
 6: v8::internal::MaybeHandle<v8::internal::Object> v8::internal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::Isolate*, v8::internal::(anonymous namespace)::BuiltinArguments<(v8::internal::BuiltinExtraArguments)1>)
 7: v8::internal::Builtin_HandleApiCall(int, v8::internal::Object**, v8::internal::Isolate*)
 8: 0x187971b0961b
(node) v8::ObjectTemplate::Set() with non-primitive values is deprecated
(node) and will stop working in the next major release.

[super-long list of JS + C stack traces omitted]

Ref. nodejs/node#6216 and nodejs/node#6228 — starting with Node.js v6, setting non-primitive values on FunctionTemplate and ObjectTemplate instances is discouraged (and triggers a stack trace). v7 will downright disallow it.

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