exogen / exogen/postinstall-build

It doesn't see a devDependencies executable on npm 5.4.1

Open
#31 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
92
Forks
12
PR merge metrics
No merged PRs in 30d

Description

I have a package with this `package.json`:

```json
{
"name": "@perevezentsev/decode-video",
"version": "3.0.0",
"description": "Decodes video using ffmpeg into raw RGBA32 frames",
"main": "./built/index.js",
"scripts": {
"build": "tsc || true",
"build:watch": "tsc --watch",
"test": "tape ./built/**/*.test.js | tap-spec",
"start": "node ./example/",
"postinstall": "postinstall-build ./built"
},
"author": "Ivan Perevezentsev ",
"license": "UNLICENSED",
"private": true,
"dependencies": {
"@types/node": "^8.0.28",
"chunking-streams": "0.0.8",
"fluent-ffmpeg": "^2.1.2",
"mkdirp": "^0.5.1",
"png-async": "^0.9.2",
"postinstall-build": "^5.0.1",
"rimraf": "^2.6.1"
},
"devDependencies": {
"eslint": "^4.2.0",
"eslint-config-airbnb-base": "^11.2.0",
"eslint-plugin-import": "^2.7.0",
"tap-spec": "^4.1.1",
"tape": "^4.8.0",
"typescript": "^2.5.2"
}
}
```

When running `npm install` in a project using this package, `postinstall-build` is triggered correctly, but npm `build` script doesn't see TypeScript compiler which is in the `devDependencies`:

```
➜ test npm i -S ../video-decoder2

> @perevezentsev/decode-video@3.0.0 postinstall /home/vanya/Documents/prog/1.videonow/test/node_modules/@perevezentsev/decode-video
> postinstall-build ./built

postinstall-build:
This version of npm (5.4.1) may not be compatible with postinstall-build! There
are outstanding bugs in certain versions of npm that prevent it from working with
postinstall-build. See https://github.com/exogen/postinstall-build#bugs-in-npm
for more information.

> @perevezentsev/decode-video@3.0.0 build /home/vanya/Documents/prog/1.videonow/video-decoder2
> tsc || true

sh: 1: tsc: not found
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN @perevezentsev/test@1.0.0 No description
npm WARN @perevezentsev/test@1.0.0 No repository field.

+ @perevezentsev/decode-video@3.0.0
added 24 packages in 9.097s
➜ test npm -v
5.4.1
```

Are there plans to fix this for this version of npm?

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.