-
Notifications
You must be signed in to change notification settings - Fork 24.6k
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
undefined is not a function(evaluation 'object.getOwnPropertyDescriptors(arguments[i])') #23092
Comments
have the same issue here... |
have the same issue here... =)) |
Same problem |
I've updated from react native 0.55 to 0.57 and i get this error on android while on ios everything works fine. I've updated the dependencies in gradle in order to be able to build but i still get the error.. |
We are automatically closing this issue because it does not appear to follow any of the provided issue templates. Please make use of the bug report template to let us know about a reproducible bug or regression in the core React Native library. If you'd like to propose a change or discuss a feature request, there is a repository dedicated to Discussions and Proposals you may use for this purpose. |
please re-open this issue, I have the same problem like them :( |
Same problem here, android only, without reason (it was working few hours ago for me). |
@luolin2611 , that is it. I create a complete new project but the error appear at the first time running the project. |
same problem |
1 similar comment
same problem |
I also run the error for the first time, and I can’t go. |
exact same issue.. |
Same problem |
same problem |
1 similar comment
same problem |
Thanks @gabsima-nexapp , I move to iOS project to continue my work first and deal with Android later |
Same issue here. |
restart your computer to solve this problem |
Same issue here. |
same problem here |
|
I restarted (my mac) but didn't solve this problem. |
react native undefined is not an object(evaluating 'Object.getOwnPropertyDescriptors(arguments[i])') |
still no fix yet, tried the above solution |
I restarted my computer, but did not solve the problem |
I have a terrible fix. I guessed that the problem was some kind of dependency upgrade, and because React Native does not come locked to working versions, something got published and broke it. I grabbed a yarn.lock from a project from over the weekend, pasted that into my project's TL:DR;
|
@GantMan I just did the same thing. I saw mainly babel update when diffing a working version and a broken version. It is hard to tell what deps cause the break, so the best option is definitely to use a whole working lock file. |
please , reopen the issue. i have the same problem it probably because the object.getOwnPropertiesDescriptor doesn't exists anymore, the same happended on node_modules/@babel/runtime/helpers/objectSpread.js Object.defineProperties(target, Object.getOwnPropertyDescriptors(arguments[i])); but i don't know how i can solve |
same issue here |
Ok guys , i have a temporaly fix , go to node_modules/@babel/runtime/helpers/objectSpread.js find the LINE OF CODE : Object.defineProperties(target, Object.getOwnPropertyDescriptors(arguments[i])); Replace the line with this code: var source = arguments[i] != null ? arguments[i] : {};
var ownKeys = Object.keys(source);
if (typeof Object.getOwnPropertySymbols === 'function') {
ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) {
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
}));
}
ownKeys.forEach(function (key) {
defineProperty(target, key, source[key]);
}); I HOPE I CAN HELP US, THIS IS THE UNIQUE METHOD WHAT WORKS |
@rolignu2 Thanks for locating the line, so I guess this pr of babel-helpers cause the problem. It forgot to check this function in else branch. Please fix this asap @hzoo @saschanaz WorkaroundAdd the following to your
Then run |
@sunnylqm Wow merged 10 hours ago... Sad that the NPM world is like this. |
@rolignu2 Thanks for locating the line
|
@Army-92 solution works fine for me |
Thank you, it solved this problems of mine. |
Babel just published a hotfixed version. Just remove your yarn.lock and |
@sunnylqm solution worked for me , just add that lines to package.json , and run yarn then run react-native run-android |
same problem, i delete the demo and run |
run npm install in the project directory to fix the issue. This command will install the missed dependency for the react native project |
i tried it, it didn't work... |
Retry |
maybe u check with your package.json. Tried with latest react-native version 0.57 |
I solve this proplem now 1-Delete the old project and create a new project |
Hey everyone, looks like this was a Babel issue - they should have published an hotfix on their side already, in the meantime to avoid too much noise I'll lock this issue.
EDIT: the breaking change was reverted in babel/babel#9379 and released in: https://github.com/babel/babel/releases/tag/v7.3.1 Anyone facing this issue simply needs to nuke yarn lock etc. |
before it went smoothly, but after I made native react a new error occurred,
this is the problem
"undefined is not a function (evaluation 'object.getOwnPropertyDescriptors (arguments [i])')"
even though the code is not I add a little bit of input
and that makes me crazy
The text was updated successfully, but these errors were encountered: