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

Fix/improve error reporting #193

Merged

Conversation

kikkomep
Copy link
Member

@kikkomep kikkomep commented Feb 2, 2022

  • Fix detection and reporting of some errors generated when querying testing services
  • Fix method to retrieve the name of the mainEntity from RO-Crates

@@ -100,7 +100,8 @@ def dataset_name(self):

@property
def main_entity_name(self):
return self._roc_helper.mainEntity['name']
mainEntity = self._roc_helper.mainEntity
return mainEntity['name'] if mainEntity and 'name' in mainEntity else None
Copy link
Member

@simleo simleo Feb 3, 2022

Choose a reason for hiding this comment

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

Defining "name" for the main workflow is not required in Workflow RO-Crate, so we should accept the crate in that case. We can fall back to the main entity's id, which is always defined:

return mainEntity.get("name", mainEntity.id) if mainEntity else None

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.

2 participants