The current implementation of ExecuteContext::new is suitable for already built ADOs.
The functionality of this is to make an instance of execute context from deps, env, info.
By the way, the type of deps is DepsMut and its CustomQuery is Empty as a default. And the already built founctions are implemented the type of deps as DepsMut with CustomQuery = Empty .
This implementation limits its utility in custom ADO that requires deps with not empty CustomQuery.
For example,
To implement the custom ADO that sends orders to Injective Orderbook, for quering from injective, it needs the type of deps as DepsMut<InjectiveQueryWrapper>. Here the generic CustomQuery is InjectiveQueryWrapper.
In this case, ExecuteContext::new requires argument deps with empty CustomQuery, so it occurs an error.
Implementation
To address this, enhancing ExecuteContext, and all the functions that require the argument deps with generic CustomQuery.
Acceptance Criteria
All the functions that require the argument deps should support CustomQuery as a random generic query.
Description
The current implementation of
ExecuteContext::new
is suitable for already built ADOs. The functionality of this is to make an instance of execute context fromdeps
,env
,info
.By the way, the type of
deps
isDepsMut
and itsCustomQuery
isEmpty
as a default. And the already built founctions are implemented the type ofdeps
asDepsMut
withCustomQuery = Empty
. This implementation limits its utility in custom ADO that requiresdeps
with not emptyCustomQuery
.For example, To implement the custom ADO that sends orders to Injective Orderbook, for quering from injective, it needs the type of
deps
asDepsMut<InjectiveQueryWrapper>
. Here the genericCustomQuery
isInjectiveQueryWrapper
. In this case,ExecuteContext::new
requires argumentdeps
with emptyCustomQuery
, so it occurs an error.Implementation
To address this, enhancing
ExecuteContext
, and all the functions that require the argumentdeps
with genericCustomQuery
.Acceptance Criteria
All the functions that require the argument
deps
should supportCustomQuery
as a random generic query.