mardi 7 août 2018

Ember project crashes after upgrading Bootstrap from 4.1.2 to 4.1.3

I have encountered a very strange problem while updating my project dependencies. I had Bootstrap 4.0.0 installed and installing the latest (4.1.3) version makes my project unusable. While rendering the page I get those errors:

TypeError: Cannot read property 'commit' of null
    at Environment.commit (vendor.js:22569)
    at Environment.commit (vendor.js:32631)
    at InteractiveRenderer._renderRootsTransaction (vendor.js:34756)
    at InteractiveRenderer._renderRoot (vendor.js:34686)
    at InteractiveRenderer._appendDefinition (vendor.js:34611)
    at InteractiveRenderer.appendOutletView (vendor.js:34599)
    at invokeWithOnError (vendor.js:24513)
    at Queue.flush (vendor.js:24422)
    at DeferredActionQueues.flush (vendor.js:24575)

Uncaught TypeError: Cannot read property 'off' of null
    at Class.teardown (vendor.js:110423)
    at Class.willDestroyElement (vendor.js:110416)
    at Class.trigger (vendor.js:60712)
    at Class.superWrapper [as trigger] (vendor.js:58700)
    at ComponentStateBucket.destroy (vendor.js:35913)
    at SimpleBlockTracker.destroy (vendor.js:18333)
    at SimpleBlockTracker.destroy (vendor.js:18333)
    at SimpleBlockTracker.destroy (vendor.js:18333)
    at SimpleBlockTracker.destroy (vendor.js:18333)
    at UpdatableBlockTracker.destroy (vendor.js:18333)

I tried to debug it with Ember Inspector. I have three pending promises with the same trace:

Ember Inspector (Promise Trace): 
    at new Promise (http://localhost:4200/assets/vendor.js:66433:28)
    at new Enumerator (http://localhost:4200/assets/vendor.js:66009:22)
    at Function.all (http://localhost:4200/assets/vendor.js:66173:12)
    at all$1 (http://localhost:4200/assets/vendor.js:66950:20)
    at Class.sendPending (<anonymous>:801:22)
    at Class.watch (<anonymous>:861:14)
    at sendEvent (http://localhost:4200/assets/vendor.js:37374:18)
    at Class.trigger (http://localhost:4200/assets/vendor.js:52321:33)
    at wrap (<anonymous>:3462:14)

I consider it weird for a couple of reasons:

  1. After downgrading to 4.1.2, everything works fine.
  2. 4.1.3 is a bugfix release, which doesn't change anything important in the JS files.
  3. After 4.1.2 -> 4.1.3 upgrade, the only difference in yarn.lock is a version of bootstrap package, so it's not caused by the update of some Bootstrap's dependencies.

What's the reason of this behaviour?

Here's my package.json dependencies list. Thank you in advance for the help.




Aucun commentaire:

Enregistrer un commentaire