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

Refactor ContractData vs copied ContractInfoResponse #1166

Closed
ueco-jb opened this issue Nov 17, 2021 · 2 comments
Closed

Refactor ContractData vs copied ContractInfoResponse #1166

ueco-jb opened this issue Nov 17, 2021 · 2 comments

Comments

@ueco-jb
Copy link
Contributor

ueco-jb commented Nov 17, 2021

During this implementation CosmWasm/cw-plus#554
by ommision we included new structure ContractInfoResponse, which is basically copy of already existing Contract Data.
https://github.com/CosmWasm/cw-plus/blob/main/packages/multi-test/src/wasm.rs#L63-L77

ContractData should be a superset of ContractInfoResponse.
Add pinned and ibc_port to the ContractData, originally set to false and None.

@webmaster128
Copy link
Member

Seems like label is currently missing here. created is something that is not supposed to be exported if I understand this comment correctly, so we should not add it:

  // Created Tx position when the contract was instantiated.
  // This data should kept internal and not be exposed via query results. Just
  // use for sorting
  AbsoluteTxPosition created = 5;

ContractData should be a superset of ContractInfoResponse.

Doesn't that mean you need more fields in ContractData? Is there anything that should be done in this repo?

@ueco-jb
Copy link
Contributor Author

ueco-jb commented Feb 3, 2022

Doesn't that mean you need more fields in ContractData?

*ContractInfoResposne

Yeah, you're correct. At that time I though that both structures were not needed, since both were representing basically same data.
And since label could/should be added in comswasm_std, I think there's actually nothing to do here.

Thank you for pointing that out.

@ueco-jb ueco-jb closed this as completed Feb 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants