Skip to content

Symbol props not supported #7

Description

@dkebler

I am using the nodejs event emitter as a mixin and the in the latest version of nodejs 12.16 they haved added a Symbol property which breaks aggregation.

nodejs/node#31788

if I add add a console.log(prop) to the forEach loop the output is below.
You can see it throws an error when encountering a Symbol which is does have a match method because it is not a string.

I have no idea if these this new Symbol must be mixed in order for the Emitter class to work correctly but if so I have no idea of how to the do that properly.

constructor
_events
_eventsCount
_maxListeners
setMaxListeners
getMaxListeners
emit
addListener
on
prependListener
once
prependOnceListener
removeListener
off
removeAllListeners
listeners
rawListeners
listenerCount
eventNames
Symbol(kCapture)
/mnt/AllData/hacking/active-dev-repos/uci/lib/uci-utils/sync/node_modules/aggregation/src/aggregation-es6.js:1
TypeError: prop.match is not a function
    at /mnt/AllData/hacking/active-dev-repos/uci/lib/uci-utils/sync/node_modules/aggregation/src/aggregation-es6.js:50:18
    at Array.forEach (<anonymous>)
    at copyProps (/mnt/AllData/hacking/active-dev-repos/uci/lib/uci-utils/sync/node_modules/aggregation/src/aggregation-es6.js:48:8)
    at /mnt/AllData/hacking/active-dev-repos/uci/lib/uci-utils/sync/node_modules/aggregation/src/aggregation-es6.js:58:5
    at Array.forEach (<anonymous>)
    at aggregation (/mnt/AllData/hacking/active-dev-repos/uci/lib/uci-utils/sync/node_modules/aggregation/src/aggregation-es6.js:57:10)
    at Object.<anonymous> (/mnt/AllData/hacking/active-dev-repos/uci/lib/uci-utils/sync/src/sync.js:19:20)
    at Generator.next (<anonymous>)

Activity

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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions