Skip to content
This repository has been archived by the owner on Jan 13, 2024. It is now read-only.

Fix fs readdir and readdirSync #1299

Closed
wants to merge 3 commits into from
Closed

Fix fs readdir and readdirSync #1299

wants to merge 3 commits into from

Conversation

roberttod
Copy link

When used with withFileTypes, fs does not work. This issue, and the remediation is explained in this issue #1130

@erossignon
Copy link
Contributor

erossignon commented Aug 26, 2021

Thank you for the PR.
Could you add a unit test to capture the intent and demonstrate the fix ?

Copy link
Author

@roberttod roberttod left a comment

Choose a reason for hiding this comment

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

@erossignon this should be good to go

@@ -1969,29 +1969,31 @@ function payloadFileSync(pointer) {
// CHILD_PROCESS ///////////////////////////////////////////////
// /////////////////////////////////////////////////////////////

const customPromiseExecFunction = (o) => (...args) => {
Copy link
Author

Choose a reason for hiding this comment

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

Not sure how all these changes (this line and below) ended up here - I'll fix that.

Copy link
Author

Choose a reason for hiding this comment

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

Actually, looks like this was applied by the prettier pre-commit hook so assume that's okay (unless you'd like me to skip the hook)

- When withFileTypes options is passed fs.readdir should be bootstrapped else it won't read from the snapshot
@john-u
Copy link

john-u commented Dec 16, 2021

Hello, we are experiencing this issue #1130 using OCLIF and commands aren't showing in the built executable. I have pulled this PR and verified locally that it resolves our issue as well. I was wondering if there is anything we could help with to get this cleared for release? Thanks!

Copy link
Contributor

@robertsLando robertsLando left a comment

Choose a reason for hiding this comment

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

@roberttod could you revert changes to bootstrap.js dlopen method?

@jesec
Copy link
Contributor

jesec commented Feb 2, 2022

Superceded by #1495 .

@jesec jesec closed this Feb 2, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants