Skip to content
This repository has been archived by the owner on Mar 16, 2020. It is now read-only.

Error: original.line and original.column are not numbers #82

Closed
satazor opened this issue Apr 29, 2018 · 2 comments
Closed

Error: original.line and original.column are not numbers #82

satazor opened this issue Apr 29, 2018 · 2 comments

Comments

@satazor
Copy link

satazor commented Apr 29, 2018

Hello!

I was trying this minifier as an alternative to uglify in webpack but I'm hitting some issues with source maps:

Error: original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.
    at SourceMapGenerator_validateMapping [as _validateMapping] (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/webpack-sources/node_modules/source-map/lib/source-map-generator.js:276:15)
    at SourceMapGenerator_addMapping [as addMapping] (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/webpack-sources/node_modules/source-map/lib/source-map-generator.js:110:12)
    at /Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/webpack-sources/node_modules/source-map/lib/source-map-generator.js:72:17
    at Array.forEach (<anonymous>)
    at BasicSourceMapConsumer.SourceMapConsumer_eachMapping [as eachMapping] (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/webpack-sources/node_modules/source-map/lib/source-map-consumer.js:157:14)
    at Function.SourceMapGenerator_fromSourceMap [as fromSourceMap] (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/webpack-sources/node_modules/source-map/lib/source-map-generator.js:48:24)
    at SourceMapSource.node (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/webpack-sources/lib/SourceMapSource.js:32:35)
    at SourceMapSource.proto.sourceAndMap (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/webpack-sources/lib/SourceAndMapMixin.js:30:18)
    at getTaskForFile (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/webpack/lib/SourceMapDevToolPlugin.js:34:30)
    at files.forEach (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/webpack/lib/SourceMapDevToolPlugin.js:127:20)
    at Array.forEach (<anonymous>)
    at compilation.hooks.afterOptimizeChunkAssets.tap (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/webpack/lib/SourceMapDevToolPlugin.js:121:12)
    at SyncHook.eval [as call] (eval at create (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/tapable/lib/HookCodeFactory.js:17:12), <anonymous>:7:1)
    at SyncHook.lazyCompileHook [as _call] (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/tapable/lib/Hook.js:35:21)
    at hooks.optimizeChunkAssets.callAsync.err (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/webpack/lib/Compilation.js:947:42)
    at _err0 (eval at create (/Users/andrecruz/Work/moxy/moxy/react-with-moxy/node_modules/tapable/lib/HookCodeFactory.js:24:12), <anonymous>:11:1)

List of devtool values that are failing:

  • nosources-source-map
  • hidden-source-map
  • inline-source-map
  • source-map

If you want to reproduce the issue, clone https://github.com/moxystudio/react-with-moxy and https://github.com/moxystudio/react-with-moxy/blob/54f575f24db6b718639fcbcbe65033f1e33dd7d0/scripts/config/webpack/config-server.js#L230 to:

require("babel-minify-webpack-plugin")();

and then simply run $ npm run build.

@alexander-akait
Copy link
Member

@satazor we have many problem with source maps and babel-minify #68, looks like another bug from babel-minify. I think will be good create his issue in babel-minify

@satazor
Copy link
Author

satazor commented Apr 30, 2018

I will be subscribing to that issue, thanks!

Closing this out.

@satazor satazor closed this as completed Apr 30, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants