graphprotocol / block-oracle

MIT License
5 stars 11 forks source link

Enable freshness check if the subgraph is uninitialized #193

Closed neysofu closed 1 year ago

neysofu commented 1 year ago

Fixes #176.

Additionaly, this PR removes some unneeded subgraph state logic as well as the SubgraphApi trait in favor of more "real-world" testing with actual HTTP requests. The result is a simpler API i.e. the query_subgraph function.

neysofu commented 1 year ago

@tilacog I really think removing the plethora of state logic makes things easier here, but I'd like to hear your opinion before merging. We can find a hybrid approach if it doesn't convince you

tilacog commented 1 year ago

I agree with you about removing the state logic. There is no reason to keep state around if we don't compare versions as they change.