Skip to content
This repository has been archived by the owner on May 11, 2018. It is now read-only.

v1.3.0 causes build errors #235

Closed
echenley opened this issue Mar 30, 2017 · 11 comments
Closed

v1.3.0 causes build errors #235

echenley opened this issue Mar 30, 2017 · 11 comments

Comments

@echenley
Copy link

screen shot 2017-03-30 at 3 57 29 pm

.babelrc:

{
  "presets": [
    ["env", {
      "modules": false,
      "targets": {
        "browsers": ["last 3 versions"],
        "uglify": true,
      },
    }],
    "react",
    "stage-1"
  ],
  "plugins": [
    "react-hot-loader/babel",
    "transform-flow-strip-types"
  ],
  "env": {
    "development": {
      "plugins": [
        "transform-react-jsx-source",
        "flow-react-proptypes"
      ]
    },
  }
}

Babel Version: 6.23.0
Webpack Version: 2.3.2


Temp fix: pin to [email protected]

@hzoo hzoo added the i: bug label Mar 30, 2017
@philwhln
Copy link

I'm hitting this without webpack...

> babel src --out-dir build/ --ignore __tests_
Error: Cannot find module '../data/plugin-features' (While processing preset: "/Users/phil/src/otono/redux-utils/node_modules/babel-preset-env/lib/index.js")
    at Function.Module._resolveFilename (module.js:469:15)
    at Function.Module._load (module.js:417:25)
    at Module.require (module.js:497:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/Users/phil/src/otono/redux-utils/node_modules/babel-preset-env/lib/normalize-options.js:21:23)
    at Module._compile (module.js:570:32)
    at Object.Module._extensions..js (module.js:579:10)
    at Module.load (module.js:487:32)
    at tryModuleLoad (module.js:446:12)
    at Function.Module._load (module.js:438:3)

My .babelrc

{
  "presets": [
    [
      "env", { "es2015": { "modules": false } }
    ]
  ],
  "plugins": [
    "transform-es2015-modules-commonjs",
    "transform-object-rest-spread"
  ]
}

@hzoo
Copy link
Member

hzoo commented Mar 30, 2017

Thanks for reporting, looks like #216 npmignored too many files

Should be an easy and quick fix, stay tuned for 1.3.1

@echenley echenley changed the title v1.3.0 causes build errors with webpack v1.3.0 causes build errors Mar 30, 2017
@existentialism
Copy link
Member

Our bad... v1.3.1 published!

@jcreamer898
Copy link

Thanks for the quick fix.

@philwhln
Copy link

Can confirm 1.3.1 is working no our builds! 👍

@echenley
Copy link
Author

Thank you! Confirmed 1.3.1 fixes the issue. Closing.

@hzoo
Copy link
Member

hzoo commented Mar 30, 2017

Why all packages need a smoke test for if you ignore too many files 😄

@haltcase
Copy link

haltcase commented Mar 30, 2017

I was going to open a new issue, but this seems directly related. 1.3.1 didn't fix it.

Error: Cannot find module 'semver' (While processing preset: "/home/ubuntu/workspace/node_modules/babel-preset-env/lib/index.js")

1.3.0 started using require('semver') in the distributed version, but it's not in the source. 1.2.2 does not have this problem.

edit: I should clarify a bit more, the distributed version requires semver but it's not listed as a dependency. semver wasn't imported prior to 1.3.0 and I'm not sure where it gets added. If I manually npm i semver the preset works just fine.

@hzoo
Copy link
Member

hzoo commented Mar 30, 2017

@citycide #238, looks like the published version is different from src for some reason (probably built the wrong branch)

@haltcase
Copy link

haltcase commented Mar 30, 2017

Yep @hzoo I think code from #231 leaked into the releases and came without adding semver to dependencies.

@hzoo
Copy link
Member

hzoo commented Mar 30, 2017

"prepublish": "npm run build" should solve in the future

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants