Repository navigation
[pull] main from pnpm:main - #345
Merged
Merged
Conversation
updateProjectManifest previously reconstructed the pairing between each resolved direct dependency and the wanted dependency it came from — first by alias, then by specifier shape, then by array position. Every one of those is fragile: a failed optional dependency drops out of directDependencies and shifts a positional pairing (#11267), and an aliasless selector that resolves to an alias already in the manifest matches the stale aliased entry instead of the request. Carry the originating wanted dependency on each resolved direct dependency (PkgAddressOrLinkBase.wantedDependency -> ResolvedDirectDependency.wantedDependency), set where the resolver builds the result and already has it in scope, and have updateProjectManifest read rdd.wantedDependency directly. This removes all the alias/position/specifier heuristics (and the earlier normalizeGitHubBareSpecifier band-aid) and fixes both correctness gaps structurally. Adds unit tests for the failed-optional (#11267), alias-collision re-add, and aliasless-optional-failure cases. Closes #11267 --------- Co-authored-by: cyphercodes <[email protected]> Co-authored-by: Hermes Agent <[email protected]> Co-authored-by: Zoltan Kochan <[email protected]>
Adds `pnpm cat-file` functionality to the `pacquet` CLI. This extracts the base64-encoded file hash from an integrity string (e.g. `sha512-...`), decodes it, and reads the corresponding file from the CAFS store directory at `files/XX/YYYY...`. Includes a new e2e test verifying correct lookup and read operations.
…2549) Port pnpm's post-resolution manifest writer into the pacquet package-manager crate as two modules mirroring pnpm's crate boundaries: - update_project_manifest_object: port of @pnpm/pkg-manifest.utils' updateProjectManifestObject (field upsert with cross-field delete, peer-range derivation, guessDependencyType, empty-spec preservation). - update_project_manifest: port of updateProjectManifest, matching resolved direct deps to wanted deps by alias (with a github: shorthand fallback) instead of by position, including the fix from #11373. Both modules ship with the ported pnpm unit tests (14 total). They are not yet wired into add/update; that integration (surfacing resolved direct deps from Install and threading the catalog userSpecifiedBareSpecifier) is tracked in #12548. Related to #11267, #11373. Part of #12548.
Add feature-gated pnpr auth backends so deployments can build with libsql, PostgreSQL, or MySQL support instead of locking the registry to one database driver. The auth state still resolves to the existing UserBackend and TokenBackend trait objects. Configuration now accepts backend.libsql, backend.postgres/backend.postgresql, or backend.mysql and rejects selecting multiple shared databases. PostgreSQL and MySQL use a shared SQLx-backed auth implementation with driver-specific placeholder syntax. The shared auth schema uses common column types, and pnpr avoids SQLite-only upsert syntax in auth and verdict-cache writes.
#12557) `pacquet add <name>@owner/repo#sha` (and GitHub / GitLab / Bitbucket URL forms) previously saved the request verbatim. Save the resolver's shortcut form instead — `github:owner/repo#sha` — matching pnpm's saved normalizedBareSpecifier. The normalization runs only in the non-registry fallback (a git shorthand isn't claimed by the npm resolver, so no registry fetch happens), leaving registry ranges, npm: aliases, file:, link:, workspace:, and tarball URLs untouched. Related to #12548.
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
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )