Error: Aborted because ... is not accepted

See original GitHub issue

When trying to hot-update React components with webpack-hot-middleware, I receive the following error every time:

Uncaught (in promise) Error: Aborted because ./SomeComponent.js is not accepted

I’m not exactly sure why that happens… But I’ve noticed that:

I can hot-update anything else (manually replacing my redux-reducer using module.hot.accept, reload css using style-loader, etc.).

Stepping through with the debugger, I can see that in file process-update.js line 32, The callback function given to module.hot.check is never called. It seems the hotCheck() function assigns its apply parameter (the callback) to a global hotApplyOnUpdate. This function is then given to hotApply() which expects to receive an options object, and not a callback.

Searching for all usages of hotApplyOnUpdate yields:

  • Initially defined as true;
  • Assigned to be the given apply parameter every time hotCheck() is called.
  • Given as an argument to hotApply() inside hotUpdateDownloaded().

So, is it a problem with webpack’s HMR plugin?


I’m using:

webpack@2.0.5-beta
webpack-dev-middleware@1.5.1
webpack-hot-middleware@2.6.4

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:16 (4 by maintainers)

github_iconTop GitHub Comments

4reactions
glenjamincommented, Mar 10, 2016

Released as 2.10.0

0reactions
phaistoniancommented, Mar 10, 2016

@glenjamin I will give it a try the soonest, though I am afraid the release will come first since I have a hectic day to deal with.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error: Aborted because ... is not accepted · Issue #132 - GitHub
The app is not accepting the update and throws a warning Error: Aborted because ... is not accepted webpack.config module.exports ...
Read more >
Getting "Aborted because 0 is not accepted" and full page ...
I am using webpack in an existing rails app. But it isn't hot-reloading. It is simply triggering a reload every time my react...
Read more >
Error: Aborted because ... is not accepted - - Bountysource
When trying to hot-update React components with webpack-hot-middleware, I receive the following error every time:
Read more >
Getting "Aborted because 0 is not accepted" and full page ...
After 2 days of research and trying different things, I found out the simplest cause to my problem ever: in webpack.config.js, I had...
Read more >
A Deep Dive into Hot Module Replacement with Webpack ...
Currently, the application doesn't accept hot updates, because we haven't instructed it to do so. Therefore, the webpack-dev-server falls ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found