Repository navigation
feat(pacquet): add patch workflow commands - #12609
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughAdds ChangesPatch workflow implementation
Sequence DiagramssequenceDiagram
participant User
participant CliArgs_run
participant PatchArgs_run
participant patch_candidates_from_lockfile
participant WritePackageForPatch
participant write_edit_dir_state
User->>CliArgs_run: pacquet patch [email protected]
CliArgs_run->>PatchArgs_run: dir + state
PatchArgs_run->>patch_candidates_from_lockfile: raw_dependency + lockfile
patch_candidates_from_lockfile-->>PatchArgs_run: PatchCandidateSet
PatchArgs_run->>WritePackageForPatch: PatchTarget + edit_dir
WritePackageForPatch-->>PatchArgs_run: Ok(())
PatchArgs_run->>write_edit_dir_state: EditDirState { patchedPkg, applyToAll }
PatchArgs_run-->>User: print patch-commit instructions
sequenceDiagram
participant User
participant CliArgs_run
participant PatchCommitArgs_run
participant prepare_pkg_files_for_diff
participant diff_folders
participant set_patched_dependencies
participant InstallArgs
User->>CliArgs_run: pacquet patch-commit ./edit-dir
CliArgs_run->>PatchCommitArgs_run: dir + state
PatchCommitArgs_run->>prepare_pkg_files_for_diff: src (edit dir)
prepare_pkg_files_for_diff-->>PatchCommitArgs_run: PkgFilesForDiff
PatchCommitArgs_run->>diff_folders: original vs edited
diff_folders-->>PatchCommitArgs_run: patch text
PatchCommitArgs_run->>set_patched_dependencies: updated patchedDependencies
PatchCommitArgs_run-->>CliArgs_run: Ok(true)
CliArgs_run->>InstallArgs: for_patch_manifest_change().run()
InstallArgs-->>User: reinstalled
Estimated code review effort🎯 5 (Critical) | ⏱️ ~120 minutes Possibly related PRs
Suggested reviewers
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
PR Summary by QodoAdd pacquet patch workflow commands (patch, patch-commit, patch-remove) Description
Diagram
High-Level Assessment
Files changed (42)
|
Code Review by Qodo
1.
|
|
Code review by qodo was updated up to the latest commit 845ec80 |
There was a problem hiding this comment.
Actionable comments posted: 11
🧹 Nitpick comments (3)
pacquet/crates/workspace-manifest-writer/src/model.rs (1)
28-29: 📐 Maintainability & Code Quality | 🔵 Trivial | 🏗️ Heavy liftKeep patched-dependency selectors and patch-file references branded.
The new manifest model collapses the
name[@Version]selector and patch-file reference into plainStrings, which then leaks into the public setter surface and makes key/value swaps type-correct. Introduce small wrapper types at this boundary and apply the same validation discipline as upstream.As per coding guidelines, "
pacquet/**/*.rs: Declare a newtype wrapper for branded string types rather than collapsing into plainStringor&str."Also applies to: 42-43
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@pacquet/crates/workspace-manifest-writer/src/model.rs` around lines 28 - 29, The patched_dependencies field uses plain String types for both the selector keys and patch-file reference values, which lacks type safety and violates the coding guidelines that require newtype wrappers for branded string types. Create newtype wrapper types for the patched-dependency selector (the name[`@version`] part) and the patch-file reference, then replace the IndexMap<String, String> in the patched_dependencies field with the appropriate wrapped types using these newtype wrappers as keys and values. Apply the same newtype wrapper approach to the other occurrences mentioned at lines 42-43 to maintain consistency across the manifest model.Source: Coding guidelines
pacquet/crates/cli/src/cli_args/patch_commit/tests.rs (1)
1-1: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winReplace wildcard
superimport with explicit symbolsPlease switch to explicit imports to keep test dependencies clear and aligned with repository conventions.
♻️ Suggested fix
-use super::*; +use super::{ + PkgFilesForDiff, cleanup_after_diff, normalize_patches_dir_name, patch_target_from_state, + path_from_forward_slash, remove_dir_if_exists, +};As per coding guidelines, “No star imports inside module bodies. Write
use super::{Foo, bar}instead ofuse super::*;for modules you control.” As per path instructions (pacquet/CODE_STYLE_GUIDE.md), “No star imports inside module bodies.”🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@pacquet/crates/cli/src/cli_args/patch_commit/tests.rs` at line 1, Replace the wildcard import statement `use super::*;` at the beginning of the tests.rs file with explicit imports of only the symbols that are actually used within the test module. Identify which items from the parent module are referenced in the tests and list them explicitly in the use statement instead of using the wildcard pattern to maintain clarity of dependencies and align with the repository's coding guidelines.Sources: Coding guidelines, Path instructions
pacquet/crates/cli/src/cli_args/patch_remove/tests.rs (1)
1-1: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winReplace wildcard
superimport with explicit symbolsUse explicit imports here to comply with pacquet test/module style and keep symbol usage auditable.
As per coding guidelines, “No star imports inside module bodies. Write
use super::{Foo, bar}instead ofuse super::*;for modules you control.” As per path instructions (pacquet/CODE_STYLE_GUIDE.md), “No star imports inside module bodies.”🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@pacquet/crates/cli/src/cli_args/patch_remove/tests.rs` at line 1, The wildcard import statement `use super::*;` in the test file violates the code style guidelines. Replace this wildcard import with explicit imports by identifying all the symbols actually used in the tests.rs file and replace the `use super::*;` statement with `use super::{Symbol1, Symbol2, ...};` listing only the specific symbols needed from the parent module. This ensures all symbol usage remains auditable and complies with the pacquet CODE_STYLE_GUIDE.md requirements.Sources: Coding guidelines, Path instructions
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@pacquet/crates/cli/src/cli_args/patch_commit.rs`:
- Around line 124-145: The current code only calls cleanup_after_diff after both
prepare_pkg_files_for_diff and diff_folders succeed. If either operation fails
and returns an error via map_err, the cleanup is skipped and temporary
directories are left behind. Restructure the code to ensure cleanup_after_diff
is called on all paths, including error paths. This can be achieved by
extracting the operations that can fail, capturing any errors that occur,
performing cleanup unconditionally with the cleanup_after_diff function, and
then propagating the errors if they occurred. This ensures temporary directories
in clean_dir are always cleaned up regardless of whether diff preparation or the
diff operation succeeds or fails.
In `@pacquet/crates/cli/src/cli_args/patch_remove/tests.rs`:
- Around line 79-81: The test contains an early return that silently skips
execution when stdin is not a terminal, which hides potential failures in
non-interactive environments. Replace this silent skip with an explicit
precondition check that fails fast using assert! or panic! if stdin is not a
terminal, or alternatively refactor the code to remove the environment
dependency by introducing a test seam that allows mocking the terminal state
check in std::io::stdin().is_terminal().
In `@pacquet/crates/cli/src/cli_args/patch_state/tests.rs`:
- Line 1: Replace the glob import `use super::*;` at the beginning of the tests
module with explicit symbol imports. Identify all the symbols from the parent
module that are actually used within the test module, and create an explicit use
statement like `use super::{SymbolName1, SymbolName2};` instead. This makes it
clear which symbols are being imported and follows the pacquet Rust style
guidelines that prohibit star imports in module bodies.
In `@pacquet/crates/cli/src/cli_args/patch.rs`:
- Around line 93-97: The validation logic is checking the edit_dir filesystem
constraints before validating that package_name is provided. Reorder the
validations so that the package_name.ok_or(PatchError::MissingPackageName) check
occurs before the if let Some(edit_dir) block that calls resolve_path and
reject_non_empty_custom_edit_dir. This ensures that missing required inputs are
reported consistently, with package_name validation happening first before any
filesystem operations are attempted.
In `@pacquet/crates/cli/src/cli_args/patch/tests.rs`:
- Line 1: Replace the glob import `use super::*;` at the top of the tests module
with an explicit import list. Identify which items from the parent module are
actually used in the test code (such as structs, functions, or types referenced
in the test functions), and write `use super::{Item1, Item2, ...};` with only
those explicitly needed items instead of the wildcard import.
- Around line 64-67: The functions
select_patch_target_uses_dialoguer_when_no_default_target and the test at lines
74-76 silently return early when stdin is a terminal, which hides the fact that
the test did not actually execute and can mask regressions. Replace the silent
return statement with an explicit test skip macro (such as panic! with a
descriptive message or a proper skip! macro if available in your test framework)
to make it clear that the test environment is not set up correctly. This ensures
that test failures are visible rather than silently ignored.
In `@pacquet/crates/package-manager/src/patch_commit.rs`:
- Around line 243-250: The normalize_diff_output function is performing global
string replacements on the entire diff content, which can unintentionally modify
file content within the diff hunks when the replacement patterns match. Restrict
the path normalization to only the diff header/metadata lines (such as lines
starting with "---", "+++", "@@", and "diff" markers) instead of replacing
patterns globally across the entire diff. Split the diff into lines, apply the
normalization logic only to header lines, and reconstruct the diff with
unchanged file content hunks.
In `@pacquet/crates/package-manager/src/patch.rs`:
- Around line 216-218: The condition at line 216 checking git_hosted ==
Some(true) to gate GitHostedTarballFetcher is too restrictive and inconsistent
with the URL inference logic applied in lines 259-265, which already treats
codeload and pkg.pr.new URLs as git-hosted. Update the condition at line 216 to
include the same URL pattern checking logic used in lines 259-265, so that
tarball URLs with git hosting patterns are properly handled for extraction even
when the explicit git_hosted flag is not set.
In `@pacquet/crates/package-manager/src/patch/tests.rs`:
- Line 1: The glob import `use super::*;` at the beginning of the tests.rs file
violates pacquet's import conventions as specified in the CODE_STYLE_GUIDE.
Replace this with explicit imports of only the items that are actually used from
the parent module. Review the test code in this file to identify all symbols
imported from the parent scope and replace the glob import with explicit
individual imports of those specific items.
In `@pacquet/crates/workspace-manifest-writer/src/edit.rs`:
- Around line 715-723: When calculating block_end_idx to determine what to
delete when removing a top-level block like patchedDependencies, the current
logic skips non-structural lines and captures everything up to the next
structural element, which causes blank lines and comments that follow the block
to also be deleted. To fix this, adjust the logic to identify the actual end of
the block content (the last non-blank, non-comment line of that block) and then
preserve any trailing blank lines and comments that come after it, so successor
comments like the catalog section's prelude are not lost when the block is
removed.
- Around line 70-77: The condition checking whether to remove the
patchedDependencies block only handles the case where
manifest.patched_dependencies is None, but fails to handle the case where it
already exists but is empty. Modify the condition in the if statement that
checks manifest.patched_dependencies.is_none() to also check if the existing
patched_dependencies map is empty, so that stale empty patchedDependencies
blocks are properly removed from the manifest when the incoming
patched_dependencies map is empty. This ensures that both None and empty maps
result in block removal and cleanup.
---
Nitpick comments:
In `@pacquet/crates/cli/src/cli_args/patch_commit/tests.rs`:
- Line 1: Replace the wildcard import statement `use super::*;` at the beginning
of the tests.rs file with explicit imports of only the symbols that are actually
used within the test module. Identify which items from the parent module are
referenced in the tests and list them explicitly in the use statement instead of
using the wildcard pattern to maintain clarity of dependencies and align with
the repository's coding guidelines.
In `@pacquet/crates/cli/src/cli_args/patch_remove/tests.rs`:
- Line 1: The wildcard import statement `use super::*;` in the test file
violates the code style guidelines. Replace this wildcard import with explicit
imports by identifying all the symbols actually used in the tests.rs file and
replace the `use super::*;` statement with `use super::{Symbol1, Symbol2, ...};`
listing only the specific symbols needed from the parent module. This ensures
all symbol usage remains auditable and complies with the pacquet
CODE_STYLE_GUIDE.md requirements.
In `@pacquet/crates/workspace-manifest-writer/src/model.rs`:
- Around line 28-29: The patched_dependencies field uses plain String types for
both the selector keys and patch-file reference values, which lacks type safety
and violates the coding guidelines that require newtype wrappers for branded
string types. Create newtype wrapper types for the patched-dependency selector
(the name[`@version`] part) and the patch-file reference, then replace the
IndexMap<String, String> in the patched_dependencies field with the appropriate
wrapped types using these newtype wrappers as keys and values. Apply the same
newtype wrapper approach to the other occurrences mentioned at lines 42-43 to
maintain consistency across the manifest model.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 0730d779-1999-45e6-af00-e2a740aee59d
⛔ Files ignored due to path filters (1)
Cargo.lockis excluded by!**/*.lock,!Cargo.lock
📒 Files selected for processing (42)
pacquet/crates/cli/Cargo.tomlpacquet/crates/cli/src/cli_args.rspacquet/crates/cli/src/cli_args/install.rspacquet/crates/cli/src/cli_args/patch.rspacquet/crates/cli/src/cli_args/patch/tests.rspacquet/crates/cli/src/cli_args/patch_commit.rspacquet/crates/cli/src/cli_args/patch_commit/tests.rspacquet/crates/cli/src/cli_args/patch_remove.rspacquet/crates/cli/src/cli_args/patch_remove/tests.rspacquet/crates/cli/src/cli_args/patch_state.rspacquet/crates/cli/src/cli_args/patch_state/tests.rspacquet/crates/cli/tests/add.rspacquet/crates/cli/tests/approve_builds.rspacquet/crates/cli/tests/create.rspacquet/crates/cli/tests/dlx.rspacquet/crates/cli/tests/patch.rspacquet/crates/cli/tests/remove.rspacquet/crates/cli/tests/runtime.rspacquet/crates/cli/tests/test_command.rspacquet/crates/cli/tests/update.rspacquet/crates/config/src/env_overlay.rspacquet/crates/config/src/lib.rspacquet/crates/config/src/tests.rspacquet/crates/config/src/workspace_yaml.rspacquet/crates/config/src/workspace_yaml/tests.rspacquet/crates/package-manager/src/dependencies_graph_to_lockfile.rspacquet/crates/package-manager/src/dependencies_graph_to_lockfile/tests.rspacquet/crates/package-manager/src/install_package_from_registry/tests.rspacquet/crates/package-manager/src/lib.rspacquet/crates/package-manager/src/patch.rspacquet/crates/package-manager/src/patch/tests.rspacquet/crates/package-manager/src/patch_commit.rspacquet/crates/package-manager/src/patch_commit/tests.rspacquet/crates/resolving-deps-resolver/src/dedupe_injected_deps/tests.rspacquet/crates/resolving-deps-resolver/src/dedupe_peer_dependents/tests.rspacquet/crates/resolving-deps-resolver/src/dependencies_graph.rspacquet/crates/resolving-deps-resolver/src/resolve_peers.rspacquet/crates/resolving-deps-resolver/src/resolve_peers/tests.rspacquet/crates/workspace-manifest-writer/src/edit.rspacquet/crates/workspace-manifest-writer/src/lib.rspacquet/crates/workspace-manifest-writer/src/model.rspacquet/crates/workspace-manifest-writer/src/tests.rs
Integrated-Benchmark Report (Linux)Each scenario reports direct installs and pnpr installs. Bencher consumes pacquet@HEAD and pnpr@HEAD. Scenario: Isolated linker: fresh restore, cold cache + cold store
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 4.84386498512,
"stddev": 0.1801159634250337,
"median": 4.90639931432,
"user": 3.91348122,
"system": 3.4719314799999994,
"min": 4.605338563819999,
"max": 5.07205690282,
"times": [
5.007821294819999,
4.914481331819999,
4.898317296819999,
5.07205690282,
4.649690361819999,
4.605338563819999,
4.65182695682,
4.6654215388199995,
5.00762542782,
4.96607017582
]
},
{
"command": "pacquet@main",
"mean": 4.7485944813200005,
"stddev": 0.1843994248669637,
"median": 4.68872068482,
"user": 3.84284592,
"system": 3.48265398,
"min": 4.60551600982,
"max": 5.20889151682,
"times": [
5.20889151682,
4.60551600982,
4.75617229482,
4.91317441082,
4.67545134282,
4.612306289819999,
4.63323487982,
4.68074737282,
4.7037566988199995,
4.69669399682
]
},
{
"command": "pnpr@HEAD",
"mean": 2.8572372586200006,
"stddev": 0.11616096990166727,
"median": 2.8077358428199997,
"user": 2.6707654199999995,
"system": 2.99154648,
"min": 2.7372306178200003,
"max": 3.08457963282,
"times": [
2.80231900582,
2.78521762082,
2.7372306178200003,
2.77860242682,
3.08457963282,
2.89045699782,
3.03664246482,
2.86247986582,
2.81315267982,
2.78169127382
]
},
{
"command": "pnpr@main",
"mean": 2.85481021352,
"stddev": 0.11640406115736134,
"median": 2.81093229282,
"user": 2.7116928200000006,
"system": 2.9833508799999997,
"min": 2.76926463782,
"max": 3.07821263382,
"times": [
2.79328218782,
2.77139013982,
2.82858239782,
3.07821263382,
2.77362916082,
2.78905121382,
2.8358668428200002,
2.76926463782,
2.84911264782,
3.05971027282
]
}
]
}Scenario: Isolated linker: fresh restore, hot cache + hot store
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 0.6342055720800001,
"stddev": 0.014904046398222586,
"median": 0.6374179259800001,
"user": 0.37711188,
"system": 1.3180674199999998,
"min": 0.6112208529800001,
"max": 0.65791560798,
"times": [
0.61331377198,
0.6392569599800001,
0.6271774129800001,
0.6388920979800001,
0.6112208529800001,
0.65791560798,
0.6264250289800001,
0.6501805259800001,
0.63594375398,
0.6417297079800001
]
},
{
"command": "pacquet@main",
"mean": 0.6436890008800001,
"stddev": 0.07433201542483546,
"median": 0.62111447498,
"user": 0.37222817999999996,
"system": 1.3138103199999998,
"min": 0.6083497519800001,
"max": 0.8534061689800001,
"times": [
0.62414030998,
0.6083497519800001,
0.6153928119800001,
0.6414250319800001,
0.6118569449800001,
0.61992103598,
0.6112214759800001,
0.6223079139800001,
0.62886856298,
0.8534061689800001
]
},
{
"command": "pnpr@HEAD",
"mean": 0.6851887059800001,
"stddev": 0.04468582948425904,
"median": 0.6712068014800001,
"user": 0.38990378,
"system": 1.3426653199999996,
"min": 0.6573103899800001,
"max": 0.8081586209800001,
"times": [
0.6941001709800001,
0.6573103899800001,
0.67639059298,
0.6630670279800001,
0.66812651698,
0.68439303898,
0.67071379198,
0.65792709798,
0.8081586209800001,
0.6716998109800001
]
},
{
"command": "pnpr@main",
"mean": 0.69144506118,
"stddev": 0.021636002725739237,
"median": 0.6847932644800001,
"user": 0.39808978,
"system": 1.3349900199999998,
"min": 0.66247895298,
"max": 0.7245015679800001,
"times": [
0.7156819469800001,
0.6795126409800001,
0.7173411469800001,
0.6734141869800001,
0.6809214939800001,
0.6886650349800001,
0.69970101498,
0.66247895298,
0.7245015679800001,
0.67223262498
]
}
]
}Scenario: Isolated linker: fresh install, cold cache + cold store
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 4.69108077862,
"stddev": 0.041911601702744994,
"median": 4.69769486612,
"user": 3.7632375200000006,
"system": 3.3806578199999997,
"min": 4.61777393962,
"max": 4.74923998862,
"times": [
4.74151287962,
4.65938537462,
4.63881160762,
4.70955184362,
4.61777393962,
4.70000183462,
4.74923998862,
4.70930007362,
4.68984234662,
4.69538789762
]
},
{
"command": "pacquet@main",
"mean": 4.67030218222,
"stddev": 0.04505995619855229,
"median": 4.67237513762,
"user": 3.7258564200000004,
"system": 3.37786792,
"min": 4.61825662862,
"max": 4.7431532906200005,
"times": [
4.61825662862,
4.7431532906200005,
4.71360922262,
4.69970820962,
4.69144507562,
4.62098591062,
4.63576505662,
4.70251923062,
4.62427399762,
4.65330519962
]
},
{
"command": "pnpr@HEAD",
"mean": 3.1052385129199997,
"stddev": 0.04311282930924551,
"median": 3.10100305562,
"user": 2.75906332,
"system": 3.1276514199999994,
"min": 3.02912417762,
"max": 3.19186849562,
"times": [
3.07689387062,
3.08451921062,
3.13300921162,
3.09096086062,
3.11955329862,
3.12974766662,
3.02912417762,
3.08566308662,
3.19186849562,
3.11104525062
]
},
{
"command": "pnpr@main",
"mean": 3.25942839322,
"stddev": 0.16371512206280953,
"median": 3.21746800262,
"user": 2.84413382,
"system": 3.1941293199999996,
"min": 3.06686897162,
"max": 3.6329447096200003,
"times": [
3.1855423746200002,
3.33878430862,
3.16714392262,
3.21377604962,
3.22115995562,
3.22887385562,
3.41042877962,
3.6329447096200003,
3.12876100462,
3.06686897162
]
}
]
}Scenario: Isolated linker: fresh install, hot cache + hot store
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 1.3208064503000003,
"stddev": 0.010751367068635347,
"median": 1.3180746608,
"user": 1.30897986,
"system": 1.6746592399999998,
"min": 1.3062492748,
"max": 1.3397633818,
"times": [
1.3268707748000002,
1.3196019258,
1.3127748988,
1.3397633818,
1.3321144358,
1.3287327118,
1.3163249488000002,
1.3090847548000002,
1.3165473958,
1.3062492748
]
},
{
"command": "pacquet@main",
"mean": 1.3471657922,
"stddev": 0.065758247542314,
"median": 1.3217762248,
"user": 1.29355806,
"system": 1.6724213399999996,
"min": 1.3153613308,
"max": 1.5284331048000002,
"times": [
1.3153613308,
1.5284331048000002,
1.3352632178000001,
1.3185200638,
1.3706572318,
1.3202526818,
1.3232307278000002,
1.3219696158,
1.3215828338,
1.3163871138
]
},
{
"command": "pnpr@HEAD",
"mean": 1.4199301842000003,
"stddev": 0.07992595927292698,
"median": 1.3944374523,
"user": 0.60286716,
"system": 1.5252379399999998,
"min": 1.3709345768,
"max": 1.6414745508000002,
"times": [
1.4330181258,
1.3986379178000001,
1.6414745508000002,
1.4050194788,
1.3901144168000001,
1.3902369868000002,
1.4112301878000002,
1.3709345768,
1.3823905408000001,
1.3762450598
]
},
{
"command": "pnpr@main",
"mean": 1.4234076152,
"stddev": 0.05555189469225387,
"median": 1.4062000468,
"user": 0.56837946,
"system": 1.58017714,
"min": 1.3688048108000002,
"max": 1.5457492918,
"times": [
1.4987499098000001,
1.4163767638000002,
1.3805045338000002,
1.5457492918,
1.4207341338000001,
1.3688048108000002,
1.4097234878,
1.3897598318000002,
1.4009967828,
1.4026766058
]
}
]
}Scenario: Isolated linker: fresh install, cold cache + hot store
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 2.9836764386,
"stddev": 0.045925629289568205,
"median": 2.9661189188,
"user": 1.7682644,
"system": 1.9415396399999996,
"min": 2.9338660158,
"max": 3.0683503387999997,
"times": [
3.0683503387999997,
2.9589355837999998,
2.9794030688,
2.9700854478,
2.9582009387999997,
2.9826171718,
2.9621523898,
2.9338660158,
3.0656432388,
2.9575101918
]
},
{
"command": "pacquet@main",
"mean": 2.9676458549999998,
"stddev": 0.042182166703226595,
"median": 2.9609725373,
"user": 1.718552,
"system": 1.92517614,
"min": 2.9068728478,
"max": 3.0741908928,
"times": [
2.9663082517999997,
2.9540287128,
2.9635405508,
2.9718689188,
2.9470326638,
2.9562423518,
2.9779688358,
2.9068728478,
3.0741908928,
2.9584045238
]
},
{
"command": "pnpr@HEAD",
"mean": 1.3941819587000002,
"stddev": 0.02462462736743403,
"median": 1.3838943093000002,
"user": 0.5885028,
"system": 1.56880074,
"min": 1.3689568348,
"max": 1.4392705518000002,
"times": [
1.4392705518000002,
1.3752344318,
1.3802787848,
1.3726620408,
1.3867563318000002,
1.3810322868000002,
1.3963828718,
1.4290346898000001,
1.3689568348,
1.4122107628000002
]
},
{
"command": "pnpr@main",
"mean": 1.382501108,
"stddev": 0.013362506044059079,
"median": 1.3811751618,
"user": 0.5701012,
"system": 1.51606794,
"min": 1.3626989408,
"max": 1.4057185708000002,
"times": [
1.3939658978,
1.3669196378000001,
1.3947509368000002,
1.4057185708000002,
1.3626989408,
1.3775285758000002,
1.3874669708,
1.3749798688000001,
1.3848217478,
1.3761599328
]
}
]
} |
|
| Branch | pr/12609 |
| Testbed | pacquet |
Click to view all benchmark results
| Benchmark | Latency | Benchmark Result milliseconds (ms) (Result Δ%) | Upper Boundary milliseconds (ms) (Limit %) |
|---|---|---|---|
| isolated-linker.fresh-install.cold-cache.cold-store | 📈 view plot 🚷 view threshold | 4,691.08 ms(+3.33%)Baseline: 4,539.88 ms | 5,447.86 ms (86.11%) |
| isolated-linker.fresh-install.cold-cache.hot-store | 📈 view plot 🚷 view threshold | 2,983.68 ms(-1.70%)Baseline: 3,035.15 ms | 3,642.18 ms (81.92%) |
| isolated-linker.fresh-install.hot-cache.hot-store | 📈 view plot 🚷 view threshold | 1,320.81 ms(-1.67%)Baseline: 1,343.22 ms | 1,611.86 ms (81.94%) |
| isolated-linker.fresh-restore.cold-cache.cold-store | 📈 view plot 🚷 view threshold | 4,843.86 ms(+13.31%)Baseline: 4,275.01 ms | 5,130.01 ms (94.42%) |
| isolated-linker.fresh-restore.hot-cache.hot-store | 📈 view plot 🚷 view threshold | 634.21 ms(+1.65%)Baseline: 623.90 ms | 748.67 ms (84.71%) |
|
| Branch | pr/12609 |
| Testbed | pnpr |
⚠️ WARNING: No Threshold found!Without a Threshold, no Alerts will ever be generated.
Click here to create a new Threshold
For more information, see the Threshold documentation.
To only post results if a Threshold exists, set the--ci-only-thresholdsflag.
Click to view all benchmark results
| Benchmark | Latency | milliseconds (ms) |
|---|---|---|
| isolated-linker.fresh-install.cold-cache.cold-store | 📈 view plot | 3,105.24 ms |
| isolated-linker.fresh-install.cold-cache.hot-store | 📈 view plot | 1,394.18 ms |
| isolated-linker.fresh-install.hot-cache.hot-store | 📈 view plot | 1,419.93 ms |
| isolated-linker.fresh-restore.cold-cache.cold-store | 📈 view plot | 2,857.24 ms |
| isolated-linker.fresh-restore.hot-cache.hot-store | 📈 view plot | 685.19 ms |
|
Code review by qodo was updated up to the latest commit 93d3400 |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #12609 +/- ##
==========================================
+ Coverage 88.12% 88.49% +0.37%
==========================================
Files 329 335 +6
Lines 47045 48785 +1740
==========================================
+ Hits 41459 43173 +1714
- Misses 5586 5612 +26 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
Code review by qodo was updated up to the latest commit 93d3400 |
|
Code review by qodo was updated up to the latest commit 374dbe6 |
1 similar comment
|
Code review by qodo was updated up to the latest commit 374dbe6 |
|
Code review by qodo was updated up to the latest commit 93da093 |
|
Code review by qodo was updated up to the latest commit 93da093 |
|
Code review by qodo was updated up to the latest commit 53ec35e |
|
Code review by qodo was updated up to the latest commit 53ec35e |
|
Code review by qodo was updated up to the latest commit 33c835e |
|
Code review by qodo was updated up to the latest commit 33c835e |
|
Code review by qodo was updated up to the latest commit 1382c02 |
|
Code review by qodo was updated up to the latest commit 1382c02 |
|
Code review by qodo was updated up to the latest commit 88fc1cb |
1 similar comment
|
Code review by qodo was updated up to the latest commit 88fc1cb |
Summary
patch,patch-commit, andpatch-remove.patchesDir, patch state handling, patched dependency manifest edits, and lockfile patch metadata.Related to #11633.
Squash Commit Body
Checklist
pacquet/port, or the description notes what still needs porting.Written by an agent (Codex, GPT-5).
Summary by CodeRabbit
pacquet patch,pacquet patch-commit, andpacquet patch-remove.patchesDir/PNPM_CONFIG_PATCHES_DIRsupport to control where generated patch files are written.patchedDependenciesis now created/updated/removed as part of the patch lifecycle.ndjson,silent).