1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00
metamask-extension/app/scripts/controllers
Dan Finlay c7233e2cc7
Fixed Vivek's bug (#5860)
* Fixed Vivek's bug

Fixes #5850

What was happening:

It seems that his MetaMask had crashed while some new transactions had
been loading defaults. He probably had a network connectivity issue to
Infura (which we are working with Infura to address).

As a result of this network cutout, his three unapproved transactions
were not marked failed, and were not marked as `loadingDefaults =
false`, as their gas prices had not yet been estimated.

Normally this behavior is supposed to clean itself up when the
transaction controller starts up, via the
`TransactionController._onBootCleanUp()` function, but in this case,
during unlock, that function was unable to do its job because when it
requested the transaction list, the current network was in the `loading`
state, making it proceed as if there were no pending transactions.

To fix this, I am doing two things:
- Setting transactions to loadingDefaults = false in more catch blocks.
- Calling `onBootCleanUp()` when the network store's status changes, so
that it will re-trigger when loading completes.

* Fixed reference

* Fixed infinite loop bug

Was refreshing the tx list on every tx state change instead of just
network changes, creating an infinite loop.

* Add notes to tx updates to clarify logs
2018-11-29 16:08:03 -08:00
..
network ESLint fixes (#5775) 2018-11-16 14:54:55 -10:00
transactions Fixed Vivek's bug (#5860) 2018-11-29 16:08:03 -08:00
address-book.js Update AddressBookController to read from preferences store 2018-05-17 12:57:39 -02:30
balance.js eslint --fix . 2018-07-02 18:49:33 -04:00
blacklist.js blacklist + currency - report error via log instead of throw 2018-10-19 07:18:16 -04:00
computed-balances.js eslint --fix . 2018-07-02 18:49:33 -04:00
currency.js Merge branch 'sentry-enhancements2' of github.com:MetaMask/metamask-extension into sentry-enhancements2 2018-10-29 20:28:02 -04:00
detect-tokens.js add & delete tokens per account 2018-07-25 16:14:10 -04:00
infura.js Require loglevel singleton in each module that uses it 2018-04-13 17:56:28 -04:00
preferences.js Don't announce new UI to users switching back 2018-11-20 14:04:50 -03:30
provider-approval.js Use initState to avoid type-checking providerRequests in state 2018-11-26 12:06:17 -03:30
README.md add READMEs to folders, re #3427 2018-03-14 15:33:22 +02:00
recent-blocks.js Merge branch 'develop' of github.com:MetaMask/metamask-extension into network-remove-provider-engine 2018-07-03 12:42:14 -07:00
shapeshift.js Merge branch 'master' into dm-docs-1 2018-04-18 16:15:48 -02:30
token-rates.js Update Balanc3 API (#5744) 2018-11-13 14:57:43 -05:00
user-actions.js Version 4.7.1 2018-06-01 15:48:16 -07:00

Controllers

Different controllers (in the sense of *VC *View-Controller).