Skip to content

Binary exported by workspace package causes "bolt install" failure #126

Closed

Description

@bengummer
Title Description
Version 0.19.2
Type Issue
node 8.9.4
Operating System macOS 10.13.2
Short Description Binary exported by workspace package causes "bolt install" failure
Detailed description If I have a bolt workspace containing a package that has a "bin" entry in its package.json file, and also have another package in the same workspace that depends on the first bin-exporting package, then running bolt results in an error.

The error displayed is:

$ bolt
⚡️   bolt v0.19.2 (node v8.9.4)
🔎   [1/3] Validating project...
📦   [2/3] Installing project dependencies...
yarn install v1.3.2
[1/4] 🔍  Resolving packages...
[2/4] 🚚  Fetching packages...
[3/4] 🔗  Linking dependencies...
[4/4] 📃  Building fresh packages...
✨  Done in 0.14s.
🔗   [3/3] Linking workspace dependencies...
error my-bin is linked to a location outside of project node_modules: ../../packages/my-bin/index.js

Demo repo here: https://github.com/bengummer/bolt-binary-issue-demo

yarn install works in the demo repo, bolt install doesn't

Activity

  1. lukebatchelor commented on Jan 18, 2018

    @lukebatchelor
    Member

    Ah. Thats interesting. We probably need to either symlink workspace's bins to the project bin, then dependents symlink to that, or modify this check to not happen with internal deps.

    Probably option 2

  2. bengummer commented on Jan 18, 2018

    @bengummer
    ContributorAuthor

    Yeah the following tests looks like they test internal dependencies so i'm not sure why my demo repo has the issue.

    https://github.com/boltpkg/bolt/blob/41e1ed61b2/src/utils/__tests__/symlinkPackageDependencies.test.js#L104

  3. jamiehodge commented on Feb 21, 2018

    @jamiehodge

    I ran into this issue as well

  4. jamiebuilds commented on Feb 22, 2018

    @jamiebuilds
    Member

    Moving to #157

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions