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 export_parameters to metadata.json in export archives #3386

Merged
merged 6 commits into from
Oct 11, 2019

Conversation

CasperWA
Copy link
Contributor

@CasperWA CasperWA commented Oct 4, 2019

Closes #3360

Current "data structure":

{
  "export_parameters": {
    "link_follow_rules": {
      // Updated dict from config.LINK_FLAGS
    },
    "original_entities": {
      "Node": [
        // UUIDs of originally chosen Nodes that should be exported
      ],
      // Possibly also "Computer": [] and "Group": [].
      // "Node": [] May also be left out, if no Nodes were specified to be exported.
    },
    "licence_info": {
      "allowed_licenses": null, // or a list or, if the parameter was a function, a string, naming the function that was used
      "forbidden_licenses": null // same as for "allowed_licenses"
    },
    "include_comments": true, // reflects the boolean parameter of the same name
    "include_logs": true // reflects the boolean parameter of the same name
  }
}

Example, which is also added to the docs:

{
  "export_parameters": {
    "link_follow_rules": {
      "input_calc_forward': False,
      "input_calc_backward': True,
      "create_forward': True,
      "create_backward': True,
      "return_forward': True,
      "return_backward': False,
      "input_work_forward': False,
      "input_work_backward': True,
      "call_calc_forward': True,
      "call_calc_backward': False,
      "call_work_forward': True,
      "call_work_backward': False
    },
    "original_entities": {
      "Node": ["1024e35e-166b-4104-95f6-c1706df4ce15"]
    },
    "license_info": {
      "allowed_licenses": None,
      "forbidden_licenses": "Function valid_licenses was used to check for forbidden licenses"
    },
    "include_comments": True,
    "include_logs": False
  },
  // ...
}  

aiida/tools/importexport/dbexport/__init__.py Outdated Show resolved Hide resolved
aiida/tools/importexport/dbexport/__init__.py Outdated Show resolved Hide resolved
aiida/tools/importexport/dbexport/__init__.py Outdated Show resolved Hide resolved
@CasperWA CasperWA force-pushed the fix_3360_expand_metadata_json branch from 24300c0 to 70fc619 Compare October 10, 2019 11:51
@CasperWA
Copy link
Contributor Author

If/when tests succeed, this should be ready to go

Copy link
Contributor

@sphuber sphuber left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much for your submission. We have thoroughly reviewed your screening but unfortunately, for us to be able to approve this with an MPA rating, we require one final adaptation to the cut. To make the presented film palatable to Oriental Audiences, the accompanying documentation will have to reflect the state of the code. We thank you for your cooperation

docs/source/import_export/main.rst Show resolved Hide resolved
@CasperWA
Copy link
Contributor Author

I've never really understood what is meant by 'redux' anyway

Copy link
Contributor

@sphuber sphuber left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot @CasperWA . As always, the director's cut extended edition is always the best

@sphuber sphuber merged commit 28a7dc9 into aiidateam:develop Oct 11, 2019
@sphuber sphuber deleted the fix_3360_expand_metadata_json branch October 11, 2019 07:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Link rules to metadata.json in export archive
2 participants