OpenEnergyPlatform / OpenEnergyPlatform/oemetadata

Add option to some list fields to be of type array or null

Open
#192 1 comment 1 reaction 1 assignee View on GitHub

@jh-RLI is already working on this.

Since Oct 29, 2024.

part: backend 🧱 priority: low 🦥 status: blocked 🛑 type: enhancement ⚙️
Dominant language
Python
Stars
26
Forks
4
PR merge metrics
No merged PRs in 30d

Description

Description of the issue

Some fields like "isAbout" have to be of type array. If there is no element, then this field must evaluate to an empty list ([ ]) element. This is fine but creates some specific issues that are raised due to how things are currently implemented in the oeplatform.

If one create metadata for a table resource, then the oeplatform currently sets empty fields to "null". This is valid with the current release of OMI, but since OMI is reworked and now fully depends on the oemetadata´s json schema this structure is now invalid.

As far as im aware json schema and frictionless are okay with, still this could raise confusion on why the fields can be empty and if the information is even relevant in this case.

Ideas of solution

TBD: provide list of nullable fields
Add nullable option to json schema

Workflow checklist

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.