Skip to content

Support pnpm modules #1213

Open
Open
@lenchvolodymyr

Description

Preflight Checklist

  • [x ] I have read the contribution documentation for this project.
  • [ x] I agree to follow the code of conduct that this project follows, as appropriate.
  • [ x] I have searched the issue tracker for a feature request that matches the one I want to file, without success.

Problem Description

When modules installed with pnpm the pruning leads to an error like this:

Error: Failed to locate module "@azure/abort-controller" from "/home/volodymyr/projects/hackolade_pnpm/node_modules/@azure/storage-file-datalake"

        This normally means that either you have deleted this package already somehow (check your ignore settings if using electron-packager).  Or your module installation failed.

It happens because pnpm stores modules under .pnpm folder and creates symlinks only for modules in "dependencies" and "devDependencies", and probably electron-packager cannot find them.

Proposed Solution

Fix the searching of modules under the symlinks and preserve node_modules that symlinks are linked to.

Additional Information

Actually, I found the PR that fixes looking to symlinks:
MarshallOfSound/flora-colossus#16

But it doesn't preserve the origin folders, so after the packaging, it leads to broken symlinks in the node_modules folder.

So I'm wondering is there a plan to support pnpm modules structure for electron projects?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    blocked 🚫Depends on another issue either in this project or a dependency's projectenhancementFeature request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions