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

feat(node/fs): Add a chmod method to the FileHandle class #27522

Merged

Conversation

nkaradzhov
Copy link
Contributor

Add the chmod method to the FileHandle class in node compat as part of #25554

@CLAassistant
Copy link

CLAassistant commented Jan 1, 2025

CLA assistant check
All committers have signed the CLA.

@nkaradzhov
Copy link
Contributor Author

Hi @k-nasa,
Feedback much appreciated!

Copy link
Contributor

@marvinhagemeister marvinhagemeister left a comment

Choose a reason for hiding this comment

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

LGTM, left two minor nits. You can resolve these by running

./tools/format.js

ext/node/polyfills/internal/fs/handle.ts Outdated Show resolved Hide resolved
ext/node/polyfills/internal/fs/handle.ts Outdated Show resolved Hide resolved
@nkaradzhov
Copy link
Contributor Author

@marvinhagemeister thanks, ran the format script and fixed those + couple other semicolons.

@nkaradzhov nkaradzhov marked this pull request as ready for review January 2, 2025 15:47
@nkaradzhov
Copy link
Contributor Author

It looks like the test is failing in the windows build.

image image

This is working in the mac and linux tests, any ideas?

@nkaradzhov nkaradzhov force-pushed the feat_chmod_to_filehandle branch from f150fe8 to 5a7a2c9 Compare January 5, 2025 19:39
@marvinhagemeister
Copy link
Contributor

Running a quick ./tools/format.js should resolve the remaining issues.

@nkaradzhov
Copy link
Contributor Author

Thanks @marvinhagemeister, this should be ready

@nkaradzhov nkaradzhov force-pushed the feat_chmod_to_filehandle branch from 0cba694 to 2894a43 Compare January 6, 2025 14:44
Fix windows unsupported mode number

Fix windows tests

Use modes that windows can handle

use more open modes for windows
As the underlying implementation of chmod is not tested on
windows, there is no reason to test this one as well.
@nkaradzhov nkaradzhov force-pushed the feat_chmod_to_filehandle branch from 2894a43 to cb613d1 Compare January 7, 2025 10:33
@marvinhagemeister marvinhagemeister changed the title feat(node_compat): Add a chmod method to the FileHandle class feat(node/fs): Add a chmod method to the FileHandle class Jan 7, 2025
@marvinhagemeister marvinhagemeister merged commit 8cda4cf into denoland:main Jan 7, 2025
17 checks passed
@nkaradzhov nkaradzhov deleted the feat_chmod_to_filehandle branch January 7, 2025 14:37
dsherret pushed a commit that referenced this pull request Jan 9, 2025
Add the chmod method to the FileHandle class in node compat as part of
#25554
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.

4 participants