Skip to content

Require node engine versions that have Promise natively? #5

@hryanjones

Description

@hryanjones

I was trying to run shp2json from your shapefile package and I ran into an error that Promise is not defined in file-source:

/usr/local/lib/node_modules/shapefile/node_modules/path-source/node_modules/file-source/index.js:7
  return new Promise(function(resolve, reject) {
             ^
ReferenceError: Promise is not defined

According to this stackoverflow answer it looks like Node didn't add Promise until version 0.12, and I'm stuck on an earlier version because it's the version we use to build our package:

$ node --version
v0.10.25

Would it be possible to update the package.json to specify the engines supported, so it'll fail at install time? It looks like this is the way to do that.

Thanks,
Ryan

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