sedos-project / data_adapter_oemof

This respository holds the data adapters to connect oemof with the OEDatamodel-concrete.
GNU Affero General Public License v3.0
0 stars 1 forks source link

Save datapackage #37

Closed FelixMau closed 12 months ago

FelixMau commented 1 year ago

Saving Datapackage

For Building the Package datapackage.Package is used to infer datatypes.

  1. Save elements and sequences with defined Naming
  2. Build Package
  3. Add Foreign keys to descriptors
  4. Use updated descriptors to create new Package and save that package as json.

Then Foreign keys are added and the datapackage.json is saved to destination

Unrelated changes:

Adjusted Naming of foreign_keys to be the same as in tabular, as they are named foreignKeys Changed get_foreign_keys: the bus names where actually the entries that would go into bus.csv and not the correct fields.

FelixMau commented 1 year ago

After updating tests and testing #31 and #22 may be closed. I would like to work on the test on branch write datapackage json directly and review/merge before

henhuy commented 1 year ago

I don't have much time currently... @nailend could you check? sorry

nailend commented 1 year ago

After updating tests and testing #31 and #22 may be closed. I would like to work on the test on branch write datapackage json directly and review/merge before

I am a bit confused. This PR is going to close #22, right? Why do you want to merge it into add_get_foreign_keys or is this just to reduce the number of current changes, as long as its parent is not merged yet? Further work concerning the datapackage.json will be done on write datapackage json which is the associated branch for #31 and child of save_datapackage?