Repository navigation
Inconsistent presence of property in contextified object #52720
Copy link
Copy link
Closed
Labels
vmIssues and PRs related to the vm subsystem.Issues and PRs related to the vm subsystem.
Description
Activity
- added a commit that references this issue
on Apr 27, 2024 - addedvmIssues and PRs related to the vm subsystem.Issues and PRs related to the vm subsystem.
on Apr 27, 2024 @nodejs/vm
I understand why it happens:
Object.hascalls ourPropertyGetterCallbackinterceptor- We call
GetRealNamedProperty, which follows the prototype chain
Lines 477 to 478 in 6aa9047
maybe_rv = ctx->global_proxy()->GetRealNamedProperty(context, property); I don't know how to fix it though. There are cases where we want to follow the protoype and other where we don't, but I'm not sure V8 gives us enough information to know in which case we are.
Maybe the solution is to set a NamedPropertyQueryCallback (we currently don't).
- added a commit that references this issue
on May 27, 2024 I opened #53172
- added a commit that references this issue
on Jun 4, 2024 - added a commit that references this issue
on Jun 20, 2024 Re-landing at #53517
- added a commit that references this issue
on Jul 9, 2024 - added a commit that references this issue
on Jul 9, 2024 Reopened for #54463
Metadata
Metadata
Assignees
Labels
vmIssues and PRs related to the vm subsystem.Issues and PRs related to the vm subsystem.
Version
v22.0.0
Platform
Darwin Laurents-MacBook-Air.local 23.2.0 Darwin Kernel Version 23.2.0: Wed Nov 15 21:59:33 PST 2023; root:xnu-10002.61.3~2/RELEASE_ARM64_T8112 arm64
Subsystem
vm
What steps will reproduce the bug?
Tested in both v22.0.0 and v20.12.2.
How often does it reproduce? Is there a required condition?
No required condition.
What is the expected behavior? Why is that the expected behavior?
Either the property is present or it is not. So either
{ hasOwn: false, descriptor: undefined}and{ hasOwn: true, descriptor: { ... } }would be better.What do you see instead?
{ hasOwn: true, descriptor: undefined }Additional information
No response