Skip to content
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

Investigate grouping specifier and version fields by dependency name in pnpm-lock.yaml importers section to reduce merge conflicts #4725

Closed
gluxon opened this issue May 12, 2022 · 0 comments · Fixed by #5091
Assignees
Milestone

Comments

@gluxon
Copy link
Member

gluxon commented May 12, 2022

See context in pnpm/rfcs#1 (comment). Filing an issue and assigning myself for personal tracking.

Before

# pnpm-lock.yaml
importers:

  project:
    specifiers:
      react: ^1.0.0
      react-dom: ^1.0.0
    dependencies:
      react: 1.0.0
      react-dom: 1.0.0_react-dom@1.0.0

After

# pnpm-lock.yml
importers:
  project:
    dependencies:

      react:
        specifier: ^1.0.0
        version: 1.0.0_react-dom@1.0.0

      react-dom:
        specifier: ^1.0.0
        version: 1.0.0

The first version of this will be hidden behind a feature flag and limited to the PnpmLockfile serialization/deserialization stages.

@gluxon gluxon self-assigned this May 12, 2022
gluxon added a commit to gluxon/pnpm that referenced this issue May 30, 2022
This allows the `LockfileFile` to `Lockfile` conversion to be slightly
better abstracted since the type assertion is now tightly grouped with
the logic performing the conversion.

This will be useful for pnpm#4725, which operates off of the `Lockfile`
type to perform additional conversions.
gluxon added a commit to gluxon/pnpm that referenced this issue May 30, 2022
This allows the `LockfileFile` to `Lockfile` conversion to be slightly
better abstracted since the type assertion is now tightly grouped with
the logic performing the conversion.

This will be useful for pnpm#4725, which operates off of the `Lockfile`
type to perform additional conversions.
gluxon added a commit to gluxon/pnpm that referenced this issue May 30, 2022
This allows the `LockfileFile` to `Lockfile` conversion to be slightly
better abstracted since the type assertion is now tightly grouped with
the logic performing the conversion.

This will be useful for pnpm#4725, which operates off of the `Lockfile`
type to perform additional conversions.
gluxon added a commit to gluxon/pnpm that referenced this issue Jun 1, 2022
This allows the `LockfileFile` to `Lockfile` conversion to be slightly
better abstracted since the type assertion is now tightly grouped with
the logic performing the conversion.

This will be useful for pnpm#4725, which operates off of the `Lockfile`
type to perform additional conversions.
zkochan pushed a commit that referenced this issue Jun 1, 2022
…#4824)

* refactor(lockfile-file): rename lockfile var to lockfileFile

* refactor(lockfile-file): cast within convertFromLockfileFileMutable

This allows the `LockfileFile` to `Lockfile` conversion to be slightly
better abstracted since the type assertion is now tightly grouped with
the logic performing the conversion.

This will be useful for #4725, which operates off of the `Lockfile`
type to perform additional conversions.
@zkochan zkochan added this to the v7.7 milestone Jul 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants