webpack-contrib / grunt-webpack

integrate webpack into grunt build process
MIT License
268 stars 70 forks source link

"Circular reference detected" warning on watch #32

Closed avaly closed 9 years ago

avaly commented 10 years ago

Using grunt-webpack 1.0.8, webpack 1.4.8, extract-text-webpack-plugin 0.3.3, style-loader 0.8.1, css-loader 0.9.0, less-loader 0.7.7, running grunt-wepack on a watch task, the first time the watch task triggers it compiles everything fine, but the second time the watch task triggers it throws the following warning and does not compile anything:

Running "webpack:dev" (webpack) task
Warning: Circular reference detected (.plugins[0].modulesByIdentifier["/src/project/node_modules/css-loader/index.js!/src/project/node_modules/less-loader/index.js!/src/project/ui/src/less/index.less"].chunks[0].modules[0])

This warning appeared after we bump a few dependencies on our project. Previously we had the following versions: grunt-webpack 1.0.8, webpack 1.4.4, extract-text-webpack-plugin 0.2.5, style-loader 0.7.0, css-loader 0.7.1, less-loader 0.7.7 and we didn't experience this warning on the same set of files.

Don't know exactly which module is responsible for this error, but since the error message is specific to grunt, I just post this here.

avaly commented 10 years ago

Reverting the extract-text-webpack-plugin, style-loader, css-loader and less-loader to the previous versions, makes the issue go away.

shama commented 9 years ago

@avaly Is this still an issue?

avaly commented 9 years ago

Unfortunately, I don't have access to the project which presented this issue. @alepek, can you please try this again?

alepek commented 9 years ago

@shama @avaly Using grunt-webpack 1.0.11 extract-text-webpack-plugin 0.3.3 style-loader 0.8.1 css-loader 0.9.0 less-loader 0.7.7 webpack 1.4.8 OR 1.7.3

this issue is no longer present and subsequnt grunt-webpack runs work fine.

shama commented 9 years ago

:+1: Thanks!