Global `process` is undefined

I don’t know what to do.

Google Chrome tells me:

Uncaught TypeError: Cannot read property 'split' of undefined
    at Object.exports.getNodeVersion (http://localhost:3000/packages/modules.js?hash=9a2c1011adc31ece5467ccb933a5a64f848e915b:116099:38)
    at meteorInstall.node_modules.azure-storage.lib.common.common.js (http://localhost:3000/packages/modules.js?hash=9a2c1011adc31ece5467ccb933a5a64f848e915b:115693:29)
    at fileEvaluate (http://localhost:3000/packages/modules-runtime.js?hash=5b5615c907a5b9a4d19081582f04748e2ad64275:191:9)
    at require (http://localhost:3000/packages/modules-runtime.js?hash=5b5615c907a5b9a4d19081582f04748e2ad64275:116:16)
    at meteorInstall.node_modules.azure-storage.lib.services.table.tableservice.js (http://localhost:3000/packages/modules.js?hash=9a2c1011adc31ece5467ccb933a5a64f848e915b:99399:19)
    at fileEvaluate (http://localhost:3000/packages/modules-runtime.js?hash=5b5615c907a5b9a4d19081582f04748e2ad64275:191:9)
    at require (http://localhost:3000/packages/modules-runtime.js?hash=5b5615c907a5b9a4d19081582f04748e2ad64275:116:16)
    at meteorInstall.node_modules.azure-storage.lib.azure-storage.js (http://localhost:3000/packages/modules.js?hash=9a2c1011adc31ece5467ccb933a5a64f848e915b:99039:20)
    at fileEvaluate (http://localhost:3000/packages/modules-runtime.js?hash=5b5615c907a5b9a4d19081582f04748e2ad64275:191:9)
    at Module.require (http://localhost:3000/packages/modules-runtime.js?hash=5b5615c907a5b9a4d19081582f04748e2ad64275:116:16)

If you’re looking deeper it’s the following line of code, that crashes:

var parsedVersion = process.version.split('.');

If you change this maybe to:

var parsedVersion = "0.8.11".split('.');

… this line passes, but in another module there is the same problem again. What is wrong?

What I tried:

  • Re-install Meteor
  • starting from a clean new project

Following packages are installed:

meteor-base@1.0.4             # Packages every Meteor app needs to have
mobile-experience@1.0.4       # Packages for a great mobile UX
mongo@1.1.14                   # The database Meteor supports right now
blaze-html-templates@1.0.4 # Compile .html files into Meteor Blaze views
reactive-var@1.0.11            # Reactive variable for tracker
jquery@1.11.10                  # Helpful client-side library
tracker@1.1.1                 # Meteor's client-side reactive programming library

standard-minifier-css@1.3.2   # CSS minifier run for production mode
standard-minifier-js@1.2.1    # JS minifier run for production mode
es5-shim@4.6.15                # ECMAScript 5 compatibility for older browsers.
ecmascript@0.5.9              # Enable ECMAScript2015+ syntax in app code
shell-server@0.2.1            # Server-side component of the `meteor shell` command

autopublish@1.0.7             # Publish all data to the clients (for prototyping)
insecure@1.0.7                # Allow all DB writes from clients (for prototyping)
accounts-password

accounts-password@1.3.2
accounts-base@1.2.14
check@1.2.4
audit-argument-checks@1.0.7
browser-policy@1.0.9

fourseven:scss
aldeed:collection2
alanning:roles
themeteorchef:bert
static-html@1.1.11
xolvio:cleaner
practicalmeteor:mocha
xolvio:backdoor
mdg:validated-method
dburles:factory@1.0.0
ddp-rate-limiter@1.0.6
shell-server@0.2.1
tsega:bootstrap3-datetimepicker

Do you have an idea?

Greetings Benni

@benni125 Did you find the solution ?

Looking at this ancient post, their problem was likely that they were trying to use a server-only npm package on the client (azure-storage)
Which was trying to access a Node global var, which doesn’t exist on the client

1 Like

Thanks.
I looked more deeply on this issue and in my case, it happens when i am triyng to update mongodb package from 3.6.4 to 3.6.5. I ,still, don’t know why.

Someone posted the same error recently. I think it was related to an Apollo package

Yes. It was @waldgeist but i am using Apollo.

It was the Apollo Dev Tools Extension for Chrome.