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

crypto: deprecate Decipher.finaltol #19353

Closed
wants to merge 2 commits into from

Conversation

tniessen
Copy link
Member

Ever since eaf1343, Decipher.finaltol() has been an undocumented alias for Decipher.final(). Sadly, @bnoordhuis comment ("remove someday") was lost at some point in the last six years, but I believe the time has finally come.

The function has never been documented, it has no advantage over .final(), there is exactly one test which uses it, and there seems to be absolutely no usage on GitHub.

cc @danbev

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • documentation is changed or added
  • commit message follows commit guidelines

@tniessen tniessen added the semver-major PRs that contain breaking changes and should be released in the next major version. label Mar 14, 2018
@tniessen tniessen added this to the 10.0.0 milestone Mar 14, 2018
@nodejs-github-bot nodejs-github-bot added the crypto Issues and PRs related to the crypto subsystem. label Mar 14, 2018
@tniessen
Copy link
Member Author

@@ -950,11 +950,21 @@ deprecated if the assigned value is not a string, boolean, or number. In the
future, such assignment may result in a thrown error. Please convert the
property to a string before assigning it to `process.env`.

<a id="DEP00XX"></a>
### DEP00XX: crypto.Decipher.finaltol
Copy link
Contributor

Choose a reason for hiding this comment

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

Should Decipher here and below be lowercased since it's referring to a prototype method and not a static method?

Copy link
Member Author

Choose a reason for hiding this comment

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

I agree that decipher.finaltol is better than Decipher.finaltol here, but crypto.decipher.finaltol looks weird (since there is no decipher property on crypto). I changed all occurrences to lowercase and removed the crypto. prefix. Is there a better way to do this?

Copy link
Contributor

@mscdex mscdex Mar 15, 2018

Choose a reason for hiding this comment

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

I think what dropping crypto. and using lowercase is fine, especially since .final() is linked to and should give enough context.

Copy link
Member

@ChALkeR ChALkeR left a comment

Choose a reason for hiding this comment

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

Seems unused to me.

@lpinca lpinca added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Mar 16, 2018
tniessen added a commit that referenced this pull request Mar 18, 2018
PR-URL: #19353
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
@tniessen
Copy link
Member Author

Landed in 19f3927, deprecation code is DEP0105.

@tniessen tniessen closed this Mar 18, 2018
@tniessen tniessen removed the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Mar 24, 2018
tniessen added a commit to tniessen/node that referenced this pull request Apr 11, 2018
jasnell pushed a commit that referenced this pull request Apr 14, 2018
Refs: #19353

PR-URL: #19941
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com>
Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com>
@tniessen tniessen added the deprecations Issues and PRs related to deprecations. label Apr 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
crypto Issues and PRs related to the crypto subsystem. deprecations Issues and PRs related to deprecations. semver-major PRs that contain breaking changes and should be released in the next major version.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

10 participants