Tag cached request with a block number and a version
Currently, the cache is totally cleared when a new request is made. The cache is also wiped out when a new version of cutecoin is used. Currently, if the following scenario happens, errors will be thrown up :
- A new block is mined, cached is cleared
- The user is disconnected, the cache can not be totally refreshed
- Exceptions will be thrown everywhere because data could not be found in the cache
This should be changed so that :
- We don't clear the cache anymore. We replace old requests results with new requests results just on time.
- When cutecoin is started with a new version, only incompatible data from the cache is cleared. We do not redownload automatically all the transactions again.