Skip to content

make env&exports enumerable#5608

Merged
anonrig merged 1 commit intomainfrom
yagiz/make-exports-env-enumerable
Dec 1, 2025
Merged

make env&exports enumerable#5608
anonrig merged 1 commit intomainfrom
yagiz/make-exports-env-enumerable

Conversation

@anonrig
Copy link
Copy Markdown
Member

@anonrig anonrig commented Nov 28, 2025

Fixes #5603

@anonrig anonrig requested a review from a team as a code owner November 28, 2025 18:51
Copy link
Copy Markdown
Member

@kentonv kentonv left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR is missing a test. How did you test the change?

@anonrig anonrig force-pushed the yagiz/make-exports-env-enumerable branch from e040500 to 383a212 Compare November 29, 2025 15:37
@anonrig anonrig force-pushed the yagiz/make-exports-env-enumerable branch from 383a212 to ef0743c Compare November 29, 2025 15:39
@anonrig anonrig requested review from a team as code owners November 29, 2025 15:39
@anonrig anonrig merged commit edc4ba4 into main Dec 1, 2025
21 checks passed
@anonrig anonrig deleted the yagiz/make-exports-env-enumerable branch December 1, 2025 13:44
return Reflect.getOwnPropertyDescriptor(inner, prop);
const desc = Reflect.getOwnPropertyDescriptor(inner, prop);
if (desc) {
return { ...desc, enumerable: true };
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Odd, why are these properties not already enumerable? Where did they get marked non-enumerable?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two possible answers:

  • We're doing something weird somewhere causing the properties to not be enumerable on inner, and we should fix that and remove the work-around here.
  • Actually the properties have been enumerable all along and the bug report was incorrect? In that case this PR can be reverted except for the test.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It turns out this PR is a no-op, the test never reproduced the actual bug and passes without the PR. I opened #5647 to revert.

kentonv added a commit that referenced this pull request Dec 5, 2025
This reverts the changes to worker.ts in ef0743c -- but not the tests.

The tests pass without the change, demonstrating that the change did not actually do anything.
kentonv added a commit that referenced this pull request Dec 5, 2025
This reverts the changes to worker.ts in ef0743c -- but not the tests.

The tests pass without the change, demonstrating that the change did not actually do anything. These properties were already enumerable.
kentonv added a commit that referenced this pull request Dec 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

logging importable exports shows an empty object

4 participants