Comments (9)
The root cause is in source-map-url, which is a dep of fast-sourcemap-concat. I did a patch release of fast-sourcemap-concat that downgrades source-map-url, and it fixes this bug.
Allow your version of fast-sourcemap-concat to update to 1.3.2 and this problem should go away.
from ember-auto-import.
I just also ran into this issue. Weirdly, everything was working fine, until suddenly it didn't anymore, after updating dependencies. I tried downgrading ember-auto-import to 1.0.1 but the issue persisted.
from ember-auto-import.
Same. I had this working but now it fails. I tried downgrading luxon and ember-auto-import but it keeps failing. I'm almost sure that it's failing because of an update in webpack.
(use Ember they said, you won't have to worry about webpack they said...)
After further digging I discovered that the syntax error is in the very end of the eval'ed string, in the webpack comment:
exports.FixedOffsetZone = FixedOffsetZone;
exports.IANAZone = IANAZone;
exports.LocalZone = LocalZone;
exports.Settings = Settings;
sourceURL=webpack://__ember_auto_import__/./node_modules/luxon/build/cjs-browser/luxon.js?
Seems that the last line should be a comment but it's not.
from ember-auto-import.
I think this is a bug in broccoli-concat. Here's the very end of the module's definition before and after concat:
exports.Settings = Settings;\n//# sourceMappingURL=luxon.js.map\n\n\n//# sourceURL=webpack://__ember_auto_import__/./node_modules/luxon/build/cjs-browser/luxon.js?");
exports.Settings = Settings;\nsourceURL=webpack://__ember_auto_import__/./node_modules/luxon/build/cjs-browser/luxon.js?");
from ember-auto-import.
@cibernox's repro app stops being broken if you disable sourcemaps:
diff --git a/ember-cli-build.js b/ember-cli-build.js
index dc5a39e..89729fe 100644
--- a/ember-cli-build.js
+++ b/ember-cli-build.js
@@ -5,6 +5,9 @@ const EmberAddon = require('ember-cli/lib/broccoli/ember-addon');
module.exports = function(defaults) {
let app = new EmberAddon(defaults, {
// Add options here
+ sourcemaps: {
+ enabled: false
+ }
});
/*
from ember-auto-import.
Maybe it's the concatenation of sourcemaps?
from ember-auto-import.
I'm pretty confident this is a bug in the sourcemap-aware concatenation in either broccoli-concat or fast-sourcemap-concat. If somebody can reduce this failure to a test case there it would help.
For now, the best workaround is disabling sourcemaps in your app.
from ember-auto-import.
Was able to narrow down the dependency causing the issue to fast-sourcemap-concat 1.3.1 release.
Opened an issue there: ef4/fast-sourcemap-concat#53
from ember-auto-import.
from ember-auto-import.
Related Issues (20)
- Cannot find require and module definitions when upgrading to v2 HOT 1
- `instanceof` fails in classic mode HOT 4
- css imports not working until referenced
- Embroider app doesn't detect runtime changes of v2 addon HOT 1
- Transitive Dependency Resolution Breaks Build on Recursive v2 Addons HOT 2
- "Require is not defined" HOT 1
- Add polyfill use case to FAQ HOT 4
- Dynamic import missing fingerprint URL HOT 1
- Add option to disable decorator transforms in case we are using a different decorator transform plugin HOT 1
- Importing does not work HOT 7
- Error loading fingerprinted lazy engine assets after moving to ember-auto-import v2 HOT 1
- "import * as ... from ..." syntax breaks when upgrading from ember-auto-import 2.6.3 to 2.7.2 HOT 2
- issue with gts/gjs if ts transform is enabled HOT 13
- error after ember upgrade - Module not found: Error: Can't resolve 'ember-qunit/qunit-module' HOT 2
- Strange import behavior with pdfjs v4 HOT 2
- `allowAppImports` entries are now allowed to import from other `allowAppImports` entries. HOT 4
- No AMD shim when alias is referencing absolute path
- Virtual modules from plugins are not importable
- Cannot dynamically import a component with `allowAppImports`
- v2 addons are not bundled when listed in dependencies of lazy-loading engine (weirdo fix attached)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ember-auto-import.