Meteor-Files: Cannot find module 'graceful-fs'

I’m upgrading to 1.7.9 to fix #349 and get this error:

C:\Users\vubui\AppData\Local\.meteor\packages\meteor-tool\1.4.2_6\mt-os.windows.x86_32\dev_bundle\server-lib\node_modules\fibers\future.js:280
						throw(ex);
						^

Error: Cannot find module 'graceful-fs'
    at Function.Module._resolveFilename (module.js:325:15)
    at Function.Module._load (module.js:276:25)
    at Module.require (module.js:353:17)
    at require (internal/module.js:12:17)
    at Object.<anonymous> (C:\Users\vubui\AppData\Local\.meteor\packages\ostrio_files\1.7.9\npm\node_modules\fs-extra\lib\index.js:4:11)
    at Module._compile (module.js:409:26)
    at Object.Module._extensions..js (module.js:416:10)
    at Module.load (module.js:343:32)
    at Function.Module._load (module.js:300:12)
    at Module.require (module.js:353:17)
    at require (internal/module.js:12:17)
Exited with code: 1
Your application is crashing. Waiting for file change.

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 15 (5 by maintainers)

Commits related to this issue

Most upvoted comments

@abernix

I experienced weird behavior. After publishing package everything went well.

Unless I ran:

meteor reset && meteor
[[[[[ ~/Sites/ostrio:files-demo/demo ]]]]]    

=> Started proxy.                             
=> Started MongoDB.                           
I20170214-22:17:10.146(3)? [FilesCollection.storagePath] Set to: assets/app/uploads/uploadedFiles
W20170214-22:17:10.247(3)? (STDERR) /Users/drdimitru/.meteor/packages/meteor-tool/.1.4.2_7.1krbw9w++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/server-lib/node_modules/fibers/future.js:280
W20170214-22:17:10.248(3)? (STDERR) 						throw(ex);
W20170214-22:17:10.248(3)? (STDERR) 						^
W20170214-22:17:10.249(3)? (STDERR) 
W20170214-22:17:10.249(3)? (STDERR) Error: Cannot find module 'graceful-fs'
W20170214-22:17:10.249(3)? (STDERR)     at Function.Module._resolveFilename (module.js:325:15)
W20170214-22:17:10.249(3)? (STDERR)     at Function.Module._load (module.js:276:25)
W20170214-22:17:10.250(3)? (STDERR)     at Module.require (module.js:353:17)
W20170214-22:17:10.250(3)? (STDERR)     at require (internal/module.js:12:17)
W20170214-22:17:10.250(3)? (STDERR)     at Object.<anonymous> (/Users/drdimitru/Sites/ostrio:files-demo/demo/node_modules/fs-extra/lib/index.js:4:11)
W20170214-22:17:10.250(3)? (STDERR)     at Module._compile (module.js:409:26)
W20170214-22:17:10.251(3)? (STDERR)     at Object.Module._extensions..js (module.js:416:10)
W20170214-22:17:10.251(3)? (STDERR)     at Module.load (module.js:343:32)
W20170214-22:17:10.251(3)? (STDERR)     at Function.Module._load (module.js:300:12)
W20170214-22:17:10.252(3)? (STDERR)     at Module.require (module.js:353:17)
=> Exited with code: 1

Well, then I executed:

meteor update

And for some reason it updated coffeescript (application has no direct coffeescript dependency)

coffeescript  upgraded from 1.12.0_1 to 1.12.3_1

then I decided to check what happening in npm packages:

meteor npm ls
Meteor-Files@1.7.10 /Users/drdimitru/Sites/ostrio:files-demo/demo
├─┬ async@2.1.4
│ └── lodash@4.17.4
├─┬ babel-runtime@6.22.0
│ ├── core-js@2.4.1
│ └── regenerator-runtime@0.10.1
├─┬ connect@3.5.0
│ ├─┬ debug@2.2.0
│ │ └── ms@0.7.1
│ ├─┬ finalhandler@0.5.0
│ │ ├── escape-html@1.0.3
│ │ ├─┬ on-finished@2.3.0
│ │ │ └── ee-first@1.1.1
│ │ ├── statuses@1.3.1
│ │ └── unpipe@1.0.0
│ ├── parseurl@1.3.1
│ └── utils-merge@1.0.0
├── d@0.1.1 extraneous
├─┬ dropbox@0.10.3
│ ├── open@0.0.5
│ └── xhr2@0.1.3
├── fibers@1.0.15
├─┬ fs-extra@2.0.0
│ ├── UNMET DEPENDENCY graceful-fs@^4.1.2
│ └─┬ jsonfile@2.4.0
│   └── UNMET OPTIONAL DEPENDENCY graceful-fs@^4.1.6
├─┬ gm@1.23.0
│ ├── array-parallel@0.1.3
│ ├── array-series@0.1.5
│ └─┬ cross-spawn@4.0.2
│   └─┬ lru-cache@4.0.2
│     ├── pseudomap@1.0.2
│     └── yallist@2.0.0
├─┬ http-proxy@1.16.2
│ ├── eventemitter3@1.2.0
│ └── requires-port@1.0.0
├── keypress@0.2.1
├─┬ knox@0.9.2
│ ├─┬ debug@1.0.4
│ │ └── ms@0.6.2
│ ├── mime@1.3.4
│ ├─┬ once@1.3.3
│ │ └── wrappy@1.0.2
│ ├── stream-counter@1.0.0
│ └─┬ xml2js@0.4.16
│   ├── sax@1.2.1
│   └─┬ xmlbuilder@4.2.1
│     └── lodash@4.13.1
├─┬ meteor-deque@2.1.0
│ └── double-ended-queue@2.1.0-0
├─┬ meteor-node-stubs@0.2.4
│ ├── assert@1.4.1
│ ├─┬ browserify-zlib@0.1.4
│ │ └── pako@0.2.9
│ ├─┬ buffer@4.9.1
│ │ ├── base64-js@1.2.0
│ │ ├── ieee754@1.1.8
│ │ └── isarray@1.0.0
│ ├─┬ console-browserify@1.1.0
│ │ └── date-now@0.1.4
│ ├── constants-browserify@1.0.0
│ ├─┬ crypto-browserify@3.11.0
│ │ ├─┬ browserify-cipher@1.0.0
│ │ │ ├─┬ browserify-aes@1.0.6
│ │ │ │ └── buffer-xor@1.0.3
│ │ │ ├─┬ browserify-des@1.0.0
│ │ │ │ └─┬ des.js@1.0.0
│ │ │ │   └── minimalistic-assert@1.0.0
│ │ │ └── evp_bytestokey@1.0.0
│ │ ├─┬ browserify-sign@4.0.0
│ │ │ ├── bn.js@4.11.6
│ │ │ ├── browserify-rsa@4.0.1
│ │ │ ├─┬ elliptic@6.3.2
│ │ │ │ ├── brorand@1.0.6
│ │ │ │ └── hash.js@1.0.3
│ │ │ └─┬ parse-asn1@5.0.0
│ │ │   └── asn1.js@4.9.0
│ │ ├── create-ecdh@4.0.0
│ │ ├─┬ create-hash@1.1.2
│ │ │ ├── cipher-base@1.0.3
│ │ │ ├── ripemd160@1.0.1
│ │ │ └── sha.js@2.4.8
│ │ ├── create-hmac@1.1.4
│ │ ├─┬ diffie-hellman@5.0.2
│ │ │ └── miller-rabin@4.0.0
│ │ ├── inherits@2.0.1
│ │ ├── pbkdf2@3.0.9
│ │ ├── public-encrypt@4.0.0
│ │ └── randombytes@2.0.3
│ ├── domain-browser@1.1.7
│ ├── events@1.1.1
│ ├─┬ http-browserify@1.7.0
│ │ └── Base64@0.2.1
│ ├── https-browserify@0.0.1
│ ├── os-browserify@0.2.1
│ ├── path-browserify@0.0.0
│ ├── process@0.11.9
│ ├── punycode@1.4.1
│ ├── querystring-es3@0.2.1
│ ├─┬ readable-stream@2.2.1
│ │ ├── buffer-shims@1.0.0
│ │ ├── core-util-is@1.0.2
│ │ ├── process-nextick-args@1.0.7
│ │ └── util-deprecate@1.0.2
│ ├── stream-browserify@2.0.1
│ ├── string_decoder@0.10.31
│ ├── timers-browserify@1.4.2
│ ├── tty-browserify@0.0.0
│ ├─┬ url@0.11.0
│ │ ├── punycode@1.3.2
│ │ └── querystring@0.2.0
│ ├── util@0.10.3
│ └─┬ vm-browserify@0.0.4
│   └── indexof@0.0.1
├── meteor-promise@0.8.0
├── mime@1.3.4
├─┬ mongodb@2.2.21
│ ├── es6-promise@3.2.1
│ ├─┬ mongodb-core@2.1.6
│ │ ├── bson@1.0.4
│ │ └─┬ require_optional@1.0.0
│ │   ├── resolve-from@2.0.0
│ │   └── semver@5.3.0
│ └─┬ readable-stream@2.1.5
│   ├── buffer-shims@1.0.0
│   ├── core-util-is@1.0.2
│   ├── inherits@2.0.3
│   ├── isarray@1.0.0
│   ├── process-nextick-args@1.0.7
│   ├── string_decoder@0.10.31
│   └── util-deprecate@1.0.2
├─┬ node-gyp@3.5.0
│ ├─┬ fstream@1.0.10
│ │ └── UNMET DEPENDENCY graceful-fs@^4.1.2
│ ├─┬ glob@7.1.1
│ │ ├── fs.realpath@1.0.0
│ │ ├─┬ inflight@1.0.6
│ │ │ └── wrappy@1.0.2
│ │ ├── once@1.4.0
│ │ └── path-is-absolute@1.0.1
│ ├── UNMET DEPENDENCY graceful-fs@^4.1.2
│ ├─┬ minimatch@3.0.3
│ │ └─┬ brace-expansion@1.1.6
│ │   ├── balanced-match@0.4.2
│ │   └── concat-map@0.0.1
│ ├─┬ mkdirp@0.5.1
│ │ └── minimist@0.0.8
│ ├─┬ nopt@3.0.6
│ │ └── abbrev@1.0.9
│ ├─┬ npmlog@4.0.2
│ │ ├─┬ are-we-there-yet@1.1.2
│ │ │ └── delegates@1.0.0
│ │ ├── console-control-strings@1.1.0
│ │ ├─┬ gauge@2.7.2
│ │ │ ├── aproba@1.0.4
│ │ │ ├── has-unicode@2.0.1
│ │ │ ├── object-assign@4.1.1
│ │ │ ├── signal-exit@3.0.2
│ │ │ ├─┬ string-width@1.0.2
│ │ │ │ ├── code-point-at@1.1.0
│ │ │ │ └─┬ is-fullwidth-code-point@1.0.0
│ │ │ │   └── number-is-nan@1.0.1
│ │ │ ├─┬ strip-ansi@3.0.1
│ │ │ │ └── ansi-regex@2.1.1
│ │ │ ├── supports-color@0.2.0
│ │ │ └── wide-align@1.1.0
│ │ └── set-blocking@2.0.0
│ ├─┬ osenv@0.1.4
│ │ ├── os-homedir@1.0.2
│ │ └── os-tmpdir@1.0.2
│ ├── rimraf@2.5.4
│ ├─┬ tar@2.2.1
│ │ └── block-stream@0.0.9
│ └─┬ which@1.2.12
│   └── isexe@1.1.2
├─┬ node-pre-gyp@0.6.32
│ ├─┬ rc@1.1.6
│ │ ├── deep-extend@0.4.1
│ │ ├── ini@1.3.4
│ │ ├── minimist@1.2.0
│ │ └── strip-json-comments@1.0.4
│ └─┬ tar-pack@3.3.0
│   ├── fstream-ignore@1.0.5
│   ├── once@1.3.3
│   └── uid-number@0.0.6
├── progress@1.1.8
├─┬ promise@7.1.1
│ └── asap@2.0.5
├─┬ request@2.79.0
│ ├── aws-sign2@0.6.0
│ ├── aws4@1.5.0
│ ├── caseless@0.11.0
│ ├─┬ combined-stream@1.0.5
│ │ └── delayed-stream@1.0.0
│ ├── extend@3.0.0
│ ├── forever-agent@0.6.1
│ ├─┬ form-data@2.1.2
│ │ └── asynckit@0.4.0
│ ├─┬ har-validator@2.0.6
│ │ ├─┬ chalk@1.1.3
│ │ │ ├── ansi-styles@2.2.1
│ │ │ ├── escape-string-regexp@1.0.5
│ │ │ ├── has-ansi@2.0.0
│ │ │ └── supports-color@2.0.0
│ │ ├─┬ commander@2.9.0
│ │ │ └── graceful-readlink@1.0.1
│ │ ├─┬ is-my-json-valid@2.15.0
│ │ │ ├── generate-function@2.0.0
│ │ │ ├─┬ generate-object-property@1.2.0
│ │ │ │ └── is-property@1.0.2
│ │ │ ├── jsonpointer@4.0.1
│ │ │ └── xtend@4.0.1
│ │ └─┬ pinkie-promise@2.0.1
│ │   └── pinkie@2.0.4
│ ├─┬ hawk@3.1.3
│ │ ├── boom@2.10.1
│ │ ├── cryptiles@2.0.5
│ │ ├── hoek@2.16.3
│ │ └── sntp@1.0.9
│ ├─┬ http-signature@1.1.1
│ │ ├── assert-plus@0.2.0
│ │ ├─┬ jsprim@1.3.1
│ │ │ ├── extsprintf@1.0.2
│ │ │ ├── json-schema@0.2.3
│ │ │ └── verror@1.3.6
│ │ └─┬ sshpk@1.10.2
│ │   ├── asn1@0.2.3
│ │   ├── assert-plus@1.0.0
│ │   ├── bcrypt-pbkdf@1.0.0
│ │   ├─┬ dashdash@1.14.1
│ │   │ └── assert-plus@1.0.0
│ │   ├── ecc-jsbn@0.1.1
│ │   ├─┬ getpass@0.1.6
│ │   │ └── assert-plus@1.0.0
│ │   ├── jodid25519@1.0.2
│ │   ├── jsbn@0.1.0
│ │   └── tweetnacl@0.14.5
│ ├── is-typedarray@1.0.0
│ ├── isstream@0.1.2
│ ├── json-stringify-safe@5.0.1
│ ├─┬ mime-types@2.1.14
│ │ └── mime-db@1.26.0
│ ├── oauth-sign@0.8.2
│ ├── qs@6.3.0
│ ├── stringstream@0.0.5
│ ├─┬ tough-cookie@2.3.2
│ │ └── punycode@1.4.1
│ ├── tunnel-agent@0.4.3
│ └── uuid@3.0.1
├── semver@5.3.0
├─┬ sockjs@0.3.18
│ ├─┬ faye-websocket@0.10.0
│ │ └─┬ websocket-driver@0.6.5
│ │   └── websocket-extensions@0.1.1
│ └── uuid@2.0.3
├─┬ source-map-support@0.3.2
│ └─┬ source-map@0.1.32
│   └── amdefine@1.0.1
├── stream-buffers@3.0.1
├─┬ throttle@1.0.3
│ └── stream-parser@0.3.1
├── underscore@1.8.3
└─┬ useragent@2.1.11
  └── lru-cache@2.2.4

npm ERR! extraneous: d@0.1.1 /Users/drdimitru/Sites/ostrio:files-demo/demo/node_modules/d
npm ERR! missing: graceful-fs@^4.1.2, required by fs-extra@2.0.0
npm ERR! missing: graceful-fs@^4.1.2, required by node-gyp@3.5.0
npm ERR! missing: graceful-fs@^4.1.2, required by fstream@1.0.10

Then I removed node_modues directory inside application, and installed only required NPM packages for my application:

meteor npm install --save gm knox request dropbox
Meteor-Files@1.7.10 /Users/drdimitru/Sites/ostrio:files-demo/demo
├─┬ dropbox@0.10.3 
│ └── xhr2@0.1.4 
├─┬ fs-extra@2.0.0
│ └── graceful-fs@4.1.11 
├── gm@1.23.0 
├─┬ knox@0.9.2 
│ └─┬ xml2js@0.4.17 
│   └── sax@1.2.2 
└─┬ request@2.79.0 
  ├── aws4@1.6.0 
  └─┬ http-signature@1.1.1
    └─┬ sshpk@1.10.2
      ├── bcrypt-pbkdf@1.0.1 
      └── jsbn@0.1.1 

Looks, fine, still has some NPM minor dependency issues, but runs fine. What’s weird - the Dockerfile disappeared from root of the app, and git showed it as removed.

Anyways, now everything is fine. This info might be useful for other folks who may run into similar behavior.

Hope it will also help to @abernix and @benjamn to make meteor-tool better.