Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"ReferenceError: Can't find variable: process" after update to 0.14.2 #4098

Closed
robinsmedberg opened this issue Nov 12, 2015 · 18 comments
Closed
Labels
Resolution: Locked This issue was locked by the bot.

Comments

@robinsmedberg
Copy link

Hi,

I updated to version 0.14.2 from 0.13 and getting errors referring to variable "process" that does not yet exist.

First location it fails is here in the main.jsbundle:

var ReactPerf={
enableMeasure:false,
storedMeasure:_noMeasure,
measureMethods:function(object,objectName,methodNames){
if(process.env.NODE_ENV !== 'production'){

My package.json:

{
"private": true,
"scripts": {
"start": "node_modules/react-native/packager/packager.sh"
},
"dependencies": {
"art": "^0.10.0",
"flux-util": "0.1.1",
"immutable": "^3.7.4",
"is-promise": "^2.0.0",
"parse": "^1.6.9",
"parse-react": "^0.5.0",
"pure-render-decorator": "^0.1.0",
"react": "^0.14.2",
"react-dom": "^0.14.2",
"react-native": "^0.14.2",
"react-native-carousel": "^0.3.5",
"react-native-image-picker": "^0.9.0",
"react-native-linear-gradient": "^1.1.0-alpha",
"react-native-navbar": "^0.5.2",
"react-native-video": "^0.6.1",
"react-pure-render": "^1.0.2",
"react-timer-mixin": "^0.13.2"
}
}

@robinsmedberg robinsmedberg changed the title ReferenceError: Can't find variable: process "ReferenceError: Can't find variable: process" after update to 0.14.2 Nov 12, 2015
@kusamakura
Copy link

I believe this is also #4022

@jsierles
Copy link
Contributor

This should be fixed in latest versions of React Native. Closing out for now!

@GeoffreyPlitt
Copy link

The recommendations all say to upgrade react to 15.2.1. I just got this same error/crash with react=15.3.1.

@cvongrim
Copy link

cvongrim commented Nov 4, 2016

Same problem here as GeoffreyPlitt. Receive the error with both react 15.2.1 and 15.3.1

@woniesong92
Copy link

This error is quite prevalent in the latest RN. It happens the most when a new npm package has been installed.

@LukeStClair
Copy link

Downgrading to 15.3.2 solved this for me. Didn't figure out the issue with 15.4.0.

@LoseTheQuit
Copy link

LoseTheQuit commented Nov 20, 2016

I've been having this same issue. I renamed one file and hit when to schittz.. I've tried downgrading my react-native package and also my react package. I can't find the right combination of [email protected]?.? with react-@15.?.? to get my app up and running. If anyone has any suggestions. Let me know please.

@matttti
Copy link

matttti commented Nov 21, 2016

I had the same error ([email protected], [email protected]). I've tried virtually everything and what finally helped was a restart of my MBP. Sounds weird, i have no idea why, but if this is of help to you, i'm happy.

@duzliang
Copy link

I had the same error after upgrade react-native(0.37.0) and react(15.4.0) , finally I downgrading the react to 15.3.2 solved this

@JonasWho
Copy link

JonasWho commented Dec 8, 2016

I am getting this error too. With RN 0.37. I've tried everything now. Restarting, changing React version etc. Nothing works. Any help out there?

@matttti
Copy link

matttti commented Dec 8, 2016

Do you use any custom babel plugins? I had one which tried to access process.env before proper initialization by RN.

@JonasWho
Copy link

JonasWho commented Dec 9, 2016

@matttti No, but after 24h of trying a million things, finally upgrading to RN 0.38 solved it. No idea why though. But thanks for the reply!

@Gelassen
Copy link

Faced with similar issue on version [email protected]. Environment: Win 7. Do you have any proposals how to solve it?

@nobalmohan
Copy link

@Gelassen Downgrade to [email protected]

@Fadingvision
Copy link

I use yarn instead of npm v5 to solves this problem(for anyone might stuck in here)

@itinance
Copy link
Contributor

having this issue with RN 0.51. Is it only me?

@roshangm1
Copy link
Contributor

@itinance I do have the issue too.

@1c7
Copy link

1c7 commented Jan 20, 2018

yep, 2018-Jan-20, RN 0.51 same problem, no idea why,

@facebook facebook locked as resolved and limited conversation to collaborators Jul 20, 2018
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Jul 20, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests