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

Proxy with preventExtensions got error: ownKeys target is non-extensible but key is missing from trap result #1063

Closed
1 task done
lovetingyuan opened this issue Jul 21, 2023 · 6 comments
Labels
bug Something isn't working need more info Awating additional info before proceeding

Comments

@lovetingyuan
Copy link

Bug Description

When I use valtio in expo, I got an error: ownKeys target is non-extensible but key is missing from trap result.
This error does not happen when I configure the js engine to jsc.

  • I have run gradle clean and confirmed this bug does not occur with JSC

Hermes version: (sorry, I do not know how to get the version, you can check the reproduce repo.)
React Native version (if any): 0.71.8
OS version (if any): Android 13
Platform (most likely one of arm64-v8a, armeabi-v7a, x86, x86_64): arm64-v8a
expo: SDK 48

Steps To Reproduce

  1. setup expo dev, and run npm run android
  2. click detail button

code example:

https://github.com/lovetingyuan/expo-example

The Expected Behavior

no error.

@tmikov
Copy link
Contributor

tmikov commented Jul 21, 2023

Hi @lovetingyuan and thank you for reporting this.

Unfortunately we are unable to debug entire applications with dependencies in order to reproduce and identify issues. Can you please reproduce the error in a minimal example with no dependencies, executing in the Hermes CLI? Thanks!

@tmikov tmikov added the need more info Awating additional info before proceeding label Jul 21, 2023
@lovetingyuan
Copy link
Author

lovetingyuan commented Jul 24, 2023

I am sorry I can not offer a pure javascript example, @pastelmind could you offer more information perhaps.
Maybe you can take a look at pmndrs/valtio#765.

@pastelmind
Copy link

#1065 narrows the problem down to a potentially misbehaving defineProperty trap in Proxy. I'm happy to continue the discussion over there.

@lovetingyuan
Copy link
Author

Ok, thanks, If you confirm that pmndrs/valtio#764 and pmndrs/valtio#752 has the same reason that is described in #1065, I will close this issue.

@pastelmind
Copy link

pastelmind commented Jul 24, 2023

I have reasons to believe pmndrs/valtio#752 is not the actual cause. I initially thought it was, but my investigations indicate that pmndrs/valtio#760 may be the culprit. If the Hermes devs verify that #1065 is a bug, then it would confirm my hypothesis. Let's keep this issue open for now.

@tmikov
Copy link
Contributor

tmikov commented Oct 18, 2024

Closing, since no activity for an year.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working need more info Awating additional info before proceeding
Projects
None yet
Development

No branches or pull requests

3 participants