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

Potentially confusing use of [string] and other single-value type arrays in schema reference & FLMT #337

Open
pindec opened this issue Jul 15, 2021 · 2 comments
Labels
build process This issue relates to the build process schema This issue relates to the schema

Comments

@pindec
Copy link
Contributor

pindec commented Jul 15, 2021

In some places in the schema reference, we have both [string] and string listed as types, which mean the same thing, and are distinct from array[string].

Examples:

  • currency e.g. finalValue/currency | [string]
  • Organization name e.g. tender/tenderers/0/name | [string]
  • dates e.g. contractPeriod/startDate | [string]

It seems when these items are copied from the OCDS schema, and the null option is removed from the type array, only one option is left in that array, [string].

They also appear slightly differently in the FLMT:

additionalClassifications/scheme ['string'] Scheme
additionalClassifications/id string ID

And affects other types:

  • amount | [number]
  • durationInDays | [integer]

This is potentially confusing, and is likely the source of some questions about cardinality of objects in the OC4IDS schema we've had recently.

We should check for situations where only one value is in the type array and adjust it to that value only.

@pindec pindec added schema This issue relates to the schema build process This issue relates to the build process labels Jul 15, 2021
@duncandewhurst
Copy link
Contributor

This should be an easy fix in borrow_schema.py

@duncandewhurst duncandewhurst added this to the 0.9.4 milestone Nov 24, 2021
@duncandewhurst
Copy link
Contributor

Moving to iterative improvements since this change would result in no change to meaning or behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build process This issue relates to the build process schema This issue relates to the schema
Projects
None yet
Development

No branches or pull requests

2 participants