diff --git a/oracle/oracle/common/clients.py b/oracle/oracle/common/clients.py index 144842f..d28a57a 100644 --- a/oracle/oracle/common/clients.py +++ b/oracle/oracle/common/clients.py @@ -153,7 +153,8 @@ async def execute_gql_query( if results.count(item) > majority: result = item majority = results.count(item) - + else: + diff = item if majority >= len(subgraph_urls) // 2 + 1: return result - raise GraphqlConsensusError + raise GraphqlConsensusError(f"{diff} not equals to {result}") diff --git a/oracle/settings.py b/oracle/settings.py index 0fb9cd2..d255335 100644 --- a/oracle/settings.py +++ b/oracle/settings.py @@ -27,7 +27,7 @@ CONFIRMATION_BLOCKS: int = config("CONFIRMATION_BLOCKS", default=15, cast=int) # oracle -ORACLE_PROCESS_INTERVAL = config("ORACLE_PROCESS_INTERVAL", default=10, cast=int) +ORACLE_PROCESS_INTERVAL = config("ORACLE_PROCESS_INTERVAL", default=15, cast=int) IPFS_FETCH_ENDPOINTS = config( "IPFS_FETCH_ENDPOINTS", @@ -56,7 +56,7 @@ ) # keeper -KEEPER_PROCESS_INTERVAL = config("KEEPER_PROCESS_INTERVAL", default=10, cast=int) +KEEPER_PROCESS_INTERVAL = config("KEEPER_PROCESS_INTERVAL", default=60, cast=int) TRANSACTION_TIMEOUT = config("TRANSACTION_TIMEOUT", default=900, cast=int)