-
Notifications
You must be signed in to change notification settings - Fork 2.3k
ci: enforce deduped lockfile when linting dependencies #6193
ci: enforce deduped lockfile when linting dependencies #6193
Conversation
834ef6e
to
b7ef0a6
Compare
b7ef0a6
to
39ffb36
Compare
Nice! The one thing I'm wondering about here is -- is there any possibility that |
@haltman-at I don't see how that would happen but I also can't promise it won't (: Thinking if it's just throwing a fit or being inconsistent, The one thing I can think of that could require intervention, though is a hypothetical future scenario like:
Now we have duplicates of If this were to happen and resolving it through upstreams isn't feasible or sufficient, I would reach for (For Bottom line I guess: If transitive dependencies violate semver then unexpected things may happen regardless - but bringing those issues to light in CI sooner than later is probably preferrable. |
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.
Well, seems good to me, I guess. We'll see what others think!
could also break out the commits into 2 separate PRs (or do a rebase-merge, in case you practice those on this repo), which would make reverting d37ed52 as easy as that without throwing out baby with water or getting conflicts in |
PR description
deduplicate:check
: exits with error if any redundancies inyarn.lock
are detecteddeduplicate
: performs a best-effort attempt to resolve such duplicateslint:dependencies
:deduplicate:check && depcheck
lint:dependencies:fix
:deduplicate && depcheck
yarn lint:dependencies
errorsyarn-deduplicate
highest
orfewer
should be used - this usesfewer
but it's a tradeoff and up to maintainer to decide iffewer
orhighest
is preferred)Blocked by
Testing instructions
Documentation
doc-change-required
label to this PR if documentation updates are required.Breaking changes and new features
breaking-change
andnew-feature
labels for the appropriate packages.