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

add list of eco credit measurement units for validation #429

Closed
4 tasks
technicallyty opened this issue Jul 22, 2021 · 4 comments
Closed
4 tasks

add list of eco credit measurement units for validation #429

technicallyty opened this issue Jul 22, 2021 · 4 comments
Labels
Scope: x/ecocredit Issues that update the x/ecocredit module Type: Feature New feature or request

Comments

@technicallyty
Copy link
Contributor

Summary

add a list of valid SI units for credit type validation

Problem Definition

in #428 we implemented credit types as a governance param which include SI units such as kg, ton, etc for each type. It would be nice to validate these parameters with a canonical list of valid SI units

Proposal

add a list of valid SI units similar to below:

if _,ok := validSIUnitMap[creditType.Unit]; ok {
 // yay
}

For Admin Use

  • Not duplicate issue
  • Appropriate labels applied
  • Appropriate contributors tagged
  • Contributor assigned/self-assigned
@technicallyty technicallyty mentioned this issue Jul 22, 2021
19 tasks
@technicallyty technicallyty added Scope: x/ecocredit Issues that update the x/ecocredit module Status: Nice To Have labels Jul 22, 2021
@ryanchristo ryanchristo added this to the v4.0 - Llangorse Upgrade milestone Mar 15, 2022
@ryanchristo
Copy link
Member

@aaronc any thoughts on this? Should we include in v4.0 upgrade?

@aaronc
Copy link
Member

aaronc commented Apr 7, 2022

I would consider this nice to have

@ryanchristo ryanchristo added the Type: Feature New feature or request label Apr 17, 2022
@ryanchristo
Copy link
Member

ryanchristo commented Apr 19, 2022

I think this might need more consideration. When attempting to write an example for biodiversity, I was not sure how to define the unit and whether that unit would fall under the SI. We also use "metric ton CO2 equivalent" in our current "carbon" credit type. I'm going to move this issue out of our current v4.0 milestone and maybe discuss with Sam before someone picks it up.

@aaronc
Copy link
Member

aaronc commented Apr 19, 2022

Having on chain validation is probably too restrictive. "metric ton CO2e" is more useful and would fail validation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Scope: x/ecocredit Issues that update the x/ecocredit module Type: Feature New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants