-
Notifications
You must be signed in to change notification settings - Fork 2k
Use perl
instead of replace
for dependency updates
#103216
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
Merged
+7
−220
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As a side-point: I'm somewhat confused by some of what this command is doing, and how we use it in our workflows.
On what this command is doing: Is it strictly necessary to include
distclean
and thetouch
parts of this command? It's not clear what impact those would have on a script presumably designed to update our transitive dependencies. It's also unclear what circumstances (if any) actually result inhttp://
links being included, which sounds like the sort of thing that could be a bug or edge-case no longer relevant in recent versions of Yarn.On how we use it in our workflows: While I can imagine some value in having a script like this to facilitate a task of updating transitive dependencies, I've been unable to find any documentation or internal references that mention it. I don't think it makes sense to include scripts here that aren't part of some documented procedure and require a developer to be aware of its existence through close examination of
package.json
.Personally, I'd rather take the opposite stance, and remove any and all commands that aren't directly referenced as part of CI or documented workflows. And if that disrupts someone's own personal workflow, then the onus should be on them to either make it a documented or CI-integrated process, or find another way to use it locally if it's not valuable to be common to the project.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we look at git history, can we find why this code was introduced? We may have more context and be able to make a better decision about keeping it or removing it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good call! It looks like it has a very long history, originating back to an old Makefile task added in #5386 (reviewed by a familiar face! 😂 ) and was originally documented in a
docs/shrinkwrap.md
file. I'm guessing as we switched to Yarn the documentation was lost or replaced, resulting in the command not being referenced anywhere.The
http:
stuff itself was added in #29718, which specifically dealt with a NPM issue. I'd imagine it probably doesn't even apply for Yarn.In summary, I think we could probably just remove this command altogether.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, let's get rid of it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed in #103307