Closed wgwz closed 1 year ago
Note: there is an inconsistency as well, we generally expect offsetGenerationMethod to be a list, but in the example shared here it is a string value. This will be part of fixing this issue.
@wgwz I believe we'd rather use offsetGenerationMethods
(plural) when it's a list and offsetGenerationMethod
(singular) when it's a string
Hey @S4mmyb 👋 I just wanted to attempt to sync you up on the issue here.
@blushi pointed out in a separate task that we had an issue with the regen:offsetGenerationMethod
.
That brought us to this current thread I'm replying to right now, it's a related issue.
So the issue is as follows:
regen:offsetGenerationMethod
in both our SHACL schema and ops dataregen:offsetGenerationMethod
should be a list (in credit classes)regen:offsetGenerationMethod
should be a string (in projects)@blushi and I discussed two possible solutions for this.
regen:offsetGenerationMethods
and the string version would be called regen:offsetGenerationMethod
. However, this would mean that we would need to update the credit classes metadata on-chain (because we made the name of the field plural).regen:offsetGenerationMethod
. This would only require that we update project metadata to use the list version, which we already need to do for project metadata separation (#37).The second solution could be beneficial if a project would ever have more than one offset generation method. Is that a conceivable possibility at this time?
I think we should just do a single regen:offsetGenerationMethod
which is a list of strings where the user can only have a single one if they chose, so probably option two. In the long term we will likely only have one offsetGenerationMethod
, but some credit classes may have two so providing the option for both makes sense.
I think the second option indeed gives us the most flexibility in case we want to support multiple offset generation methods per project in the future. The only comment that I have is that for fields that are supposed to be lists , we sometimes use plural (eg regen:projectActivities
), and sometimes singular (regen:sectoralScope
) which is not very consistent... Maybe not something we need to fix now but I guess it might be important once we start defining our regen
schema and vocabulary more precisely.
We missed this part of the SHACL schema prior to going live with C02.
regen-web changes/effects for this can be seen with the following data through the compaction in the jsonld-playground:
jsonld input:
jsonld context (from regen-web):
output (see offsetGenerationMethod):
Note: there is an inconsistency as well, we generally expect offsetGenerationMethod to be a list, but in the example shared here it is a string value. This will be part of fixing this issue.
/cc @mhagel