Repository navigation
Closed
Milestone
Description
Do you want to request a feature or report a bug?
bug
What is the current behavior?
Webpack is generating the following error when running our build:
Error: Error: ENAMETOOLONG: name too long, open '/mnt/tmp/d20180130-23474-fmx2zd/monorail-solano-ghe/public/static/AsyncTwoFactorModal~LuxuryCreateInspection_async~LuxuryListingStatusDashboard_async~SaveToListModal~UserChallengesInline~UserChallengesModalWrapper~business_profile_modal_content~causesAdminCampaignModal~causesAdminCauseModal~mt-guest-services-RestaurantBookContainer~mt-guest-services-confirmAndPayContainer~reauthModal_async-async-33b40edd34cd932e7a21.js'
at multiCompiler.run (/mnt/tmp/d20180130-23474-fmx2zd/monorail-solano-ghe/webpack/compile.js:16:11)
at runWithDependencies (/mnt/tmp/d20180130-23474-fmx2zd/monorail-solano-ghe/node_modules/webpack/lib/MultiCompiler.js:223:20)
at /mnt/tmp/d20180130-23474-fmx2zd/monorail-solano-ghe/node_modules/async/dist/async.js:1074:9
at /mnt/tmp/d20180130-23474-fmx2zd/monorail-solano-ghe/node_modules/async/dist/async.js:421:16
at iteratorCallback (/mnt/tmp/d20180130-23474-fmx2zd/monorail-solano-ghe/node_modules/async/dist/async.js:996:13)
at /mnt/tmp/d20180130-23474-fmx2zd/monorail-solano-ghe/node_modules/async/dist/async.js:906:16
at /mnt/tmp/d20180130-23474-fmx2zd/monorail-solano-ghe/node_modules/async/dist/async.js:1071:13
at fn (/mnt/tmp/d20180130-23474-fmx2zd/monorail-solano-ghe/node_modules/webpack/lib/MultiCompiler.js:166:21)
at compiler.run (/mnt/tmp/d20180130-23474-fmx2zd/monorail-solano-ghe/node_modules/webpack/lib/MultiCompiler.js:218:21)
at emitAssets.err (/mnt/tmp/d20180130-23474-fmx2zd/monorail-solano-ghe/node_modules/webpack/lib/Compiler.js:179:20)
It looks like webpack is combining several of our async imported file names into one.
If the current behavior is a bug, please provide the steps to reproduce.
I don't know how to recreate outside of running our build.
What is the expected behavior?
The above error shouldn't be generated.
If this is a feature request, what is motivation or use case for changing the behavior?
Please mention other relevant information such as the browser version, Node.js version, webpack version and Operating System.
node 8.9.1, npm 5.6.0, webpack 4 beta, mac osx
Reacted by joshjg, ibio, Dimitri KOPRIWA and seven
Metadata
Metadata
Assignees
Labels
No labels
Type
Fields
Priority
None yet
Activity
sokra commentedon Jan 31, 2018
Workaround:
optimization.splitChunks.name: falseor
output.chunkFilename: "[chunkhash].js"<- no[name]We should limit the automatically generated name to a maximum length. In these cases we can omit the name, that doesn't hurt.
sokra commentedon Jan 31, 2018
Somebody can send a PR
Truncate chunk generated chunk name if too long
delagen commentedon Feb 1, 2018
@sokra This issue also when use
with chunkName1~chunkName2......~chunkNameN path
Truncate generated chunk name if too long
Truncate generated chunk name if too long
gdborton commentedon Feb 6, 2018
failed our build with:
Trying the other workaround now.
allow name: false for splitChunks