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

TypeError: attempted to use private field on non-instance, js engine: hermes #2111

Open
4 tasks done
manufunk opened this issue Apr 17, 2024 · 2 comments
Open
4 tasks done
Labels
type:bug Impaired feature or lacking behavior that is likely assumed

Comments

@manufunk
Copy link

New Issue Checklist

Issue Description

If using react native and expo, I receive an error if I do something like const parseQuery = new Parse.Query("Config");.
This happened after upgrading the parse library. It seems that 4.x is affected and also the 5.0.0

Steps to reproduce

I created a sample project that will end up in an error. Just use yarn install and then yarn run start.
I tested on the android emulator via expo app. However same happens on ios.

Actual Outcome

The following error is thrown:

 ERROR  TypeError: attempted to use private field on non-instance, js engine: hermes
 ERROR  Invariant Violation: "main" has not been registered. This can happen if:
* Metro (the local dev server) is run from the wrong folder. Check if Metro is running, stop it and restart it in the current project.
* A module failed to load due to an error and `AppRegistry.registerComponent` wasn't called., js engine: hermes

Expected Outcome

No such error.
The sample shows that if switched back to 3.5.1, the error does not appear but it is very old.

Client

  • Parse JS SDK version: 5.0.0

Sample for reproduction

example.zip

Copy link

Thanks for opening this issue!

  • 🚀 You can help us to fix this issue faster by opening a pull request with a failing test. See our Contribution Guide for how to make a pull request, or read our New Contributor's Guide if this is your first time contributing.

@dplewis
Copy link
Member

dplewis commented Apr 17, 2024

I believe this has been fixed via #2109

Can you try the latest alpha release?

@mtrezza mtrezza added the type:bug Impaired feature or lacking behavior that is likely assumed label Apr 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Impaired feature or lacking behavior that is likely assumed
Projects
None yet
Development

No branches or pull requests

3 participants