Getline-Network / getline

Distributed P2P Lending System
https://getline.in
Apache License 2.0
9 stars 6 forks source link

Ensure fresh loan state data is used in the metabackend #71

Closed q3k closed 6 years ago

q3k commented 6 years ago

The state transition of a Loan from (Fundraising|GatheringCollateral)->Finished (due to timing out) or (FUndraising)->Finished (due to defaulting) happens automatically via the timedTransitions modifier. The way we currently get the contract state on the metabackend does not trigger this transition so we don't notice such timeouts. To remedy this:

We also drive-by clean up getter calls to return more descriptive errors when calling a getter fails. This was required when we were debugging a Truffle miscompilation issue while working on this commit.