kumlien / fx2

fx trade, second try...
1 stars 0 forks source link

Mark older candles as complete when we get a new one #44

Closed kumlien closed 7 years ago

kumlien commented 7 years ago

Seem like we have a lot of old candles in the db which are not complete, not so good. Why is that? Probably not good enough to just mark them as complete...

kumlien commented 7 years ago

When the system is restarted the last candle, which might not be complete, is not updated. Either change the query when starting the fetch procedure (give me last COMPLETE candle) or delete the last candle before running the query (only ideas...)

kumlien commented 7 years ago

Kind of hacky: request the two latest candles, filter out the non complete ones (should be only the last one if any) and then save the complete candles.