Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upfs: undeprecate lchown() #21498
Conversation
This comment has been minimized.
This comment has been minimized.
nodejs-github-bot
added
the
libuv
label
Jun 24, 2018
This comment has been minimized.
This comment has been minimized.
benjamingr
reviewed
Jun 24, 2018
|
|
||
| <a id="DEP0038"></a> | ||
| ### DEP0038: fs.lchownSync(path, uid, gid) | ||
|
|
||
| Type: Documentation-only | ||
|
|
||
| The [`fs.lchownSync(path, uid, gid)`][] API is deprecated. | ||
| The [`fs.lchownSync(path, uid, gid)`][] API was previously deprecated. As of |
This comment has been minimized.
This comment has been minimized.
benjamingr
Jun 24, 2018
Member
Given it was never hard-deprecated or removed - I'm not sure it's not best to remove this entirely.
benjamingr
reviewed
Jun 24, 2018
| @@ -1918,6 +1920,8 @@ changes: | |||
| pr-url: https://github.com/nodejs/node/pull/7897 | |||
| description: The `callback` parameter is no longer optional. Not passing | |||
| it will emit a deprecation warning with id DEP0013. | |||
| - version: v0.4.7 | |||
This comment has been minimized.
This comment has been minimized.
benjamingr
Jun 24, 2018
Member
I also think it makes sense to remove the deprecation entirely since there is no effect about this being deprecated in earlier versions and it was doc-deprecated anyway.
benjamingr
reviewed
Jun 24, 2018
| pr-url: https://github.com/nodejs/node/pull/XXXXX-replace | ||
| description: This API is no longer deprecated. | ||
| - version: v10.0.0 | ||
| description: This API is deprecated. |
This comment has been minimized.
This comment has been minimized.
benjamingr
Jun 24, 2018
Member
I don't see a point in keeping this deprecation regardless of the other one since fsPromises is experimental
benjamingr
reviewed
Jun 24, 2018
| const int argc = args.Length(); | ||
| CHECK_GE(argc, 3); | ||
|
|
||
| BufferValue path(env->isolate(), args[0]); |
This comment was marked as off-topic.
This comment was marked as off-topic.
benjamingr
reviewed
Jun 24, 2018
| @@ -0,0 +1,50 @@ | |||
| 'use strict'; | |||
|
|
|||
| const common = require('../common'); | |||
This comment has been minimized.
This comment has been minimized.
benjamingr
Jun 24, 2018
Member
If there are other tests you think we should add to lchown, let me know and we'll make good-first-issues out of them
This comment has been minimized.
This comment has been minimized.
cjihrig
Jun 25, 2018
Author
Contributor
We're pretty light on chown(), fchown(), and lchown() happy path tests in general. My guess is because of platform support and getting the uid and gid parts right on the CI.
This comment has been minimized.
This comment has been minimized.
|
Code of commit 5a08026 LGTM but would prefer it if someone with more libuv experience approves :) Nice work! |
cjihrig
force-pushed the
cjihrig:lchown
branch
from
5a08026
to
85c6651
Jun 25, 2018
cjihrig
referenced this pull request
Jun 25, 2018
Closed
test: add tests for fsPromises.chown to increase coverage #20574
geek
approved these changes
Jun 26, 2018
cjihrig
force-pushed the
cjihrig:lchown
branch
3 times, most recently
from
11cd3f4
to
ea9d597
Jun 27, 2018
cjihrig
force-pushed the
cjihrig:lchown
branch
from
ea9d597
to
7ff50f9
Jun 27, 2018
This comment has been minimized.
This comment has been minimized.
|
Updated as requested. CI: https://ci.nodejs.org/job/node-test-pull-request/15652/ |
cjihrig
merged commit 7ff50f9
into
nodejs:master
Jun 27, 2018
cjihrig
deleted the
cjihrig:lchown
branch
Jun 27, 2018
targos
added a commit
that referenced
this pull request
Jun 28, 2018
shisama
referenced this pull request
Jun 30, 2018
Merged
fs: fix fsPromises.lchmod errors on non-Mac #21435
ChALkeR
referenced this pull request
Jul 1, 2018
Merged
doc: remove 2 unused error codes from errors.md #21491
This comment has been minimized.
This comment has been minimized.
|
According the the git history, this is the first commit which removes deprecation numbers from the documentation. Is that intended? |
This comment has been minimized.
This comment has been minimized.
|
@ChALkeR As long as the deprecation number is never re-used, I'm personally OK with removing a deprecation number from the docs if it is unused in the corresponding Node.js version. (I'm also OK with leaving it in, with or without an indication that it is no longer used.) |
cjihrig commentedJun 24, 2018
•
edited
uv_fs_lchown()exists, as of libuv 1.21.0.fs.lchown()can now be undeprecated. This commit also adds tests, as there were none. As withfs.chown()andfs.fchown(), the tests are somewhat limited.Fixes: #19868
Checklist
make -j4 test(UNIX), orvcbuild test(Windows) passes