Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AureliaWebpackPlugin triggering TypeError #266

Open
alavkx opened this issue Feb 13, 2018 · 4 comments
Open

AureliaWebpackPlugin triggering TypeError #266

alavkx opened this issue Feb 13, 2018 · 4 comments

Comments

@alavkx
Copy link

alavkx commented Feb 13, 2018

Getting an error at the "advanced module optimization" stage of the build. Pulling out aurelia-webpack-plugin resolves the issue. Unfortunately, this plugin is essential for my build. Hopefully this stack trace will be helpful if you are interested in pursuing this issue.

Unhandled rejection TypeError: Cannot read property 'has' of undefined
at importedNames.importedModule.providedExports.filter.id (C:\webpack-test\app\scheduling\node_modules\webpack\lib\dependencies\HarmonyExportImportedSpecifierDependency.js:78:28)
at Array.filter ()
at HardHarmonyExportImportedSpecifierDependency.getReference (C:\webpack-test\app\scheduling\node_modules\webpack\lib\dependencies\HarmonyExportImportedSpecifierDependency.js:76:51)
at processDependency (C:\webpack-test\app\scheduling\node_modules\webpack\lib\FlagDependencyUsagePlugin.js:52:48)
at depBlock.dependencies.forEach.dep (C:\webpack-test\app\scheduling\node_modules\webpack\lib\FlagDependencyUsagePlugin.js:46:43)
at Array.forEach ()
at processDependenciesBlock (C:\webpack-test\app\scheduling\node_modules\webpack\lib\FlagDependencyUsagePlugin.js:46:28)
at Compilation.compilation.plugin.modules (C:\webpack-test\app\scheduling\node_modules\webpack\lib\FlagDependencyUsagePlugin.js:23:6)
at Compilation.applyPluginsBailResult1 (C:\webpack-test\app\scheduling\node_modules\tapable\lib\Tapable.js:140:27)
at Compilation.seal (C:\webpack-test\app\scheduling\node_modules\webpack\lib\Compilation.js:597:9)
at applyPluginsParallel.err (C:\webpack-test\app\scheduling\node_modules\webpack\lib\Compiler.js:504:17)
at C:\webpack-test\app\scheduling\node_modules\tapable\lib\Tapable.js:289:11
at C:\webpack-test\app\scheduling\node_modules\html-webpack-plugin\index.js:60:9
at tryCatcher (C:\webpack-test\app\scheduling\node_modules\bluebird\js\release\util.js:16:23)
at Promise._settlePromiseFromHandler (C:\webpack-test\app\scheduling\node_modules\bluebird\js\release\promise.js:512:31)
at Promise._settlePromise (C:\webpack-test\app\scheduling\node_modules\bluebird\js\release\promise.js:569:18)
at Promise._settlePromise0 (C:\webpack-test\app\scheduling\node_modules\bluebird\js\release\promise.js:614:10)
at Promise._settlePromises (C:\webpack-test\app\scheduling\node_modules\bluebird\js\release\promise.js:693:18)
at Async._drainQueue (C:\webpack-test\app\scheduling\node_modules\bluebird\js\release\async.js:133:16)
at Async._drainQueues (C:\webpack-test\app\scheduling\node_modules\bluebird\js\release\async.js:143:10)
at Immediate.Async.drainQueues [as _onImmediate] (C:\webpack-test\app\scheduling\node_modules\bluebird\js\release\async.js:17:14)
at runCallback (timers.js:756:18)
at tryOnImmediate (timers.js:717:5)
at processImmediate [as _immediateCallback] (timers.js:697:5)

PS: Thanks for all the hard work :). The result is very impressive

@alavkx alavkx changed the title AureliaPlugin triggering TypeError AureliaWebpackPlugin triggering TypeError Feb 13, 2018
@mzgoddard
Copy link
Owner

@alavkx Give [email protected] a try. Not sure what the 0.5 series would have been missing. Pretty sure it handled set to array and back transformation for activeExports on that dependency type. 0.6 definitely does the needed transformation for the has function to be there.

@Alexander-Taran
Copy link

@alavkx have you tried a new version of plugin?
if your issue is resolved, can we close aurelia/webpack-plugin#136 ?

@zakjan
Copy link

zakjan commented Jul 24, 2018

With aurelia-webpack-plugin, we're getting a lot of these errors:

Could not freeze xxx.(html|ts): Unfrozen dependencies (1 / 1): IncludeDependency

Is it related, or a different bug?

@mzgoddard
Copy link
Owner

@zakjan IncludeDependency is a part of aurelia-webpack-plugin. aurelia-webpack-plugin will need a plugin for hard-source so hard-source can freeze the dependency and any containing modules. hard-source will continue to freeze modules that do not contain IncludeDependency.

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

No branches or pull requests

4 participants