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

[0.65.0] no identifiers allowed directly after numeric literal #32044

Closed
aprilmintacpineda opened this issue Aug 19, 2021 · 4 comments
Closed
Labels
Needs: Triage 🔍 Resolution: Locked This issue was locked by the bot.

Comments

@aprilmintacpineda
Copy link

Please provide all the information requested. Issues that do not follow this format are likely to stall.

Description

Please provide a clear and concise description of what the bug is. Include screenshots if needed.
Please test using the latest React Native release to make sure your issue has not already been fixed: https://reactnative.dev/docs/upgrading.html

React Native version:

Run react-native info in your terminal and copy the results here.

Steps To Reproduce

Provide a detailed list of steps that reproduce the issue.

I simply upgraded from react-native 0.64.2 to 0.65.0, hermes-engine from 0.7.2 to 0.8.1 and suddenly got the error no identifiers allowed directly after numeric literal when I tried to run on ios and there was no stack.

Expected Results

Describe what you expected to happen.

Should not throw error OR at least should show a stack trace.

Snack, code example, screenshot, or link to a repository:

here are my dependencies:

"dependencies": {
  "@react-native-community/masked-view": "^0.1.11",
  "@react-native-community/netinfo": "^6.0.0",
  "@react-native-firebase/analytics": "^12.7.0",
  "@react-native-firebase/app": "^12.7.0",
  "@react-native-firebase/crashlytics": "^12.7.0",
  "@react-native-firebase/messaging": "^12.7.0",
  "@react-navigation/bottom-tabs": "^6.0.5",
  "@react-navigation/drawer": "^6.1.4",
  "@react-navigation/native": "^6.0.2",
  "@react-navigation/stack": "^6.0.7",
  "color": "^4.0.1",
  "date-fns": "^2.23.0",
  "expo-image-picker": "^10.2.2",
  "fluxible-js": "^5.0.11",
  "hermes-engine": "0.8.1",
  "husky": "7.0.1",
  "jsc-android": "^250230.2.1",
  "patch-package": "^6.4.7",
  "postinstall-postinstall": "^2.1.0",
  "react": "17.0.2",
  "react-fluxible": "^5.0.4",
  "react-native": "0.65.0",
  "react-native-add-calendar-event": "^4.0.0",
  "react-native-animatable": "^1.3.3",
  "react-native-background-timer": "^2.4.1",
  "react-native-bootsplash": "^3.2.4",
  "react-native-bouncy-checkbox": "^2.1.3",
  "react-native-camera-kit": "^11.2.1",
  "react-native-config": "^1.4.3",
  "react-native-device-info": "^8.3.0",
  "react-native-fs": "^2.18.0",
  "react-native-gesture-handler": "^1.10.3",
  "react-native-google-places": "^3.1.2",
  "react-native-maps": "^0.28.0",
  "react-native-mime-types": "^2.3.0",
  "react-native-modalize": "^2.0.8",
  "react-native-paper": "^4.9.2",
  "react-native-permissions": "^3.0.5",
  "react-native-portalize": "^1.0.7",
  "react-native-push-notification-popup": "^1.6.0",
  "react-native-qrcode-svg": "^6.1.1",
  "react-native-reanimated": "^2.2.0",
  "react-native-responsive-image-view": "^2.1.0",
  "react-native-safe-area-context": "^3.3.0",
  "react-native-screens": "^3.5.0",
  "react-native-sensitive-info": "^6.0.0-alpha.8",
  "react-native-svg": "^12.1.1",
  "react-native-unimodules": "^0.14.6",
  "react-native-vector-icons": "^8.1.0",
  "react-native-walkthrough-tooltip": "^1.2.0",
  "rn-placeholder": "^3.0.3",
  "uuid": "^8.3.2"
},
"devDependencies": {
  "@babel/core": "^7.15.0",
  "@babel/eslint-parser": "^7.15.0",
  "@babel/runtime": "^7.15.3",
  "@react-native-community/eslint-config": "^3.0.0",
  "babel-jest": "^27.0.6",
  "babel-plugin-module-resolver": "^4.0.0",
  "babel-plugin-optional-require": "^0.3.1",
  "babel-plugin-transform-remove-console": "^6.9.4",
  "command-line-args": "^5.2.0",
  "eslint": "^7.32.0",
  "eslint-import-resolver-babel-module": "^5.3.1",
  "eslint-plugin-import": "^2.24.0",
  "eslint-plugin-module-resolver": "^1.4.0",
  "eslint-plugin-react-hooks": "^4.2.0",
  "jest": "^27.0.6",
  "lint-staged": "^11.1.2",
  "metro-react-native-babel-preset": "^0.66.2",
  "prettier": "^2.3.2",
  "react-native-version": "^4.0.0",
  "react-test-renderer": "17.0.2",
  "source-map": "^0.7.3"
},
@aprilmintacpineda
Copy link
Author

image

Just tried it out again, still happens.

@aprilmintacpineda
Copy link
Author

aprilmintacpineda commented Sep 4, 2021

More info that I found

E0904 20:39:19.622335 1815965696 NativeToJsBridge.cpp:188] Attempting to call JS function on a bad application bundle: RCTLog.logIfNoNativeHook()
2021-09-04 20:39:19.628009+0800 Entrepic DEV[327:32855] [native] Unhandled JS Exception: No identifiers allowed directly after numeric literal

no stack
2021-09-04 20:39:24.867146+0800 Entrepic DEV[327:33065] [] nw_socket_handle_socket_event [C10:1] Socket SO_ERROR [61: Connection refused]
2021-09-04 20:39:24.869078+0800 Entrepic DEV[327:33071] [] nw_connection_get_connected_socket [C10] Client called nw_connection_get_connected_socket on unconnected nw_connection

@aprilmintacpineda
Copy link
Author

I finally found out why.

While building for production, I encountered this error:

error node_modules/color/index.js: Unexpected token: name (_28) in file node_modules/color/index.js at 237:33.
Error: Unexpected token: name (_28) in file node_modules/color/index.js at 237:33

Which led me to this: https://github.com/Qix-/color/issues/222
which led me to this: https://github.com/Qix-/color/issues/213
which led me to this: https://github.com/Qix-/color/issues/204
which led me to this: facebook/metro#645

So I simply had to uninstall color package and try to find something to serve as an alternative.

@hm-harshit
Copy link

@aprilmintacpineda I am also getting this same error while making bundleRelease
./gradlew bundleRelease

Error: Unexpected token: name (_28) in file node_modules/color/index.js at 237:33
error node_modules/color/index.js: Unexpected token: name (_28) in file node_modules/color/index.js at 237:33.

any way to fix this?

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

No branches or pull requests

3 participants