Skip to content

Conversation

@max-programming
Copy link
Contributor

Closes #175

….fips to crypto.getFips() and crypto.setFips()
@max-programming
Copy link
Contributor Author

Let me know if the settings.json change feels unnecessary, if that's the case, I'll remove it

Personally, I think having that helps

@avivkeller
Copy link
Member

Let me know if the settings.json change feels unnecessary, if that's the case, I'll remove it

Personally, I think having that helps

You don't have to remove it entirely, but can it be a separate PR (to keep our commits organized)?

Thank you!

@max-programming
Copy link
Contributor Author

@avivkeller Alright then. I'm gonna make another PR for another recipe where I'll include this change as a separate commit

Replaces array concatenation with generator-based iteration
to improve readability, memory usage, and performance.
Copy link
Member

@AugustinMauroy AugustinMauroy left a comment

Choose a reason for hiding this comment

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

WOW 😵‍💫 that's an awesome first contribution. I love your usage of yield.

Thanks you for your contribution, I hope that you had enjoyed it. If you have any feedback feel it

@max-programming
Copy link
Contributor Author

Thanks @AugustinMauroy!

I'll update the suggested changes
Also there's one two more test cases that are failing which I'll add and re-request a review

…tFips/setFips

This update introduces a transformation for replacing deprecated `crypto.fips` calls with `crypto.getFips()` and `crypto.setFips()`. It includes enhancements to variable collection, import specifier updates, and destructuring adjustments to ensure proper usage of the new methods. Additionally, new test cases have been added to validate the changes.
@max-programming
Copy link
Contributor Author

@AugustinMauroy I think some functions I used can be put into utils. Ones that are used to get import specifiers and all
Let me know which ones can be re-used in other codemods

@max-programming
Copy link
Contributor Author

For the utility functions thing, I'll examine those and probably open another PR for that specifically

@max-programming
Copy link
Contributor Author

max-programming commented Oct 19, 2025

Not sure why these checks fail

How can we get them to pass?

@AugustinMauroy
Copy link
Member

Not sure why these checks fail

How can we get them to pass?

because you touch to the utility and you break something

@max-programming
Copy link
Contributor Author

Ah I think I found the failing part

@max-programming
Copy link
Contributor Author

Passed finally

This was such a headache lol

@JakobJingleheimer
Copy link
Member

@max-programming thanks for this and getting it updated! I'll try to get to the review tomorrow.

Copy link
Member

@JakobJingleheimer JakobJingleheimer left a comment

Choose a reason for hiding this comment

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

This looks pretty good! It needs to support dynamic imports—we have utilities to help with that (I referenced them in some code suggestions) and tests for them; I think that will be pretty quick/simple to include. Good to go IMO once those are in 🙂

@JakobJingleheimer JakobJingleheimer added missing functionality Required use-case missing awaiting author Reviewer has requested something from the author and removed awaiting reviewer Author has responded and needs action from the reviewer labels Oct 23, 2025
@max-programming
Copy link
Contributor Author

@JakobJingleheimer Made the changes! Enabled dynamic imports (it was quite simple lol)

Also be sure to verify this settings.json change

I did it because generally my default formatter is Prettier but this project recommends Biome

Copy link
Member

@JakobJingleheimer JakobJingleheimer left a comment

Choose a reason for hiding this comment

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

🙌 Thanks!

@JakobJingleheimer JakobJingleheimer removed missing functionality Required use-case missing awaiting author Reviewer has requested something from the author labels Oct 26, 2025
@brunocroh
Copy link
Member

Thank you so much for your contribution @max-programming, You did a great job, we really appreciate it!

@brunocroh brunocroh merged commit 641d544 into nodejs:main Oct 27, 2025
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dep:v23 Migration handles deprecation introduced in node v23

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: DEP0093: crypto.fips is deprecated and replaced

5 participants