Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make "query" entry point optional #699

Closed
webmaster128 opened this issue Jan 7, 2021 · 0 comments · Fixed by #708
Closed

Make "query" entry point optional #699

webmaster128 opened this issue Jan 7, 2021 · 0 comments · Fixed by #708
Assignees
Labels
Breaking (consensus) Breaks consensus, i.e. it is possible to have contracts that create different execution results Minimal Contract Integration (IBC)
Milestone

Comments

@webmaster128
Copy link
Member

webmaster128 commented Jan 7, 2021

After #698 it becomes very easy to make the query entry point optional (just like migrate). This is probably used by most contract and best practice to have, but making it optional shows the power of the more dynamic import system and avoids placeholder implementations like this:

pub fn query(_deps: Deps, _env: Env, _msg: QueryMsg) -> StdResult<QueryResponse> {
    Err(StdError::generic_err(
        "You can only use this contract for migrations",
    ))
}
@webmaster128 webmaster128 added this to the 0.14.0 milestone Jan 7, 2021
@webmaster128 webmaster128 self-assigned this Jan 7, 2021
@webmaster128 webmaster128 added the Breaking (consensus) Breaks consensus, i.e. it is possible to have contracts that create different execution results label Jan 11, 2021
@mergify mergify bot closed this as completed in #708 Jan 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Breaking (consensus) Breaks consensus, i.e. it is possible to have contracts that create different execution results Minimal Contract Integration (IBC)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant