Provenance

Extract provenance information from the repository.

Activities

class renku.core.models.provenance.activities.Activity(*, commit=None, client=None, path=None, label=NOTHING, project: renku.core.models.projects.Project = None, id=None, message=NOTHING, was_informed_by=NOTHING, part_of=None, generated=None, invalidated=None, influenced=NOTHING, started_at_time=NOTHING, ended_at_time=NOTHING, agents=NOTHING)[source]

Represent an activity in the repository.

Method generated by attrs for class Activity.

as_jsonld()[source]

Create JSON-LD.

default_agents()[source]

Set person agent to be the author of the commit.

default_ended_at_time()[source]

Configure calculated properties.

default_generated()[source]

Create default generated.

default_id()[source]

Configure calculated ID.

default_influenced()[source]

Calculate default values.

default_invalidated()[source]

Entities invalidated by this Action.

default_label()

Generate a default label.

default_message()[source]

Generate a default message.

default_reference()

Create a default reference path.

default_started_at_time()[source]

Configure calculated properties.

default_was_informed_by()[source]

List parent actions.

classmethod from_jsonld(data, client=None, commit=None)[source]

Create an instance from JSON-LD data.

classmethod from_yaml(path, client=None, commit=None)[source]

Return an instance from a YAML file.

classmethod generate_id(commitsha)[source]

Calculate action ID.

get_output_paths()[source]

Gets all output paths generated by this run.

nodes

Return topologically sorted nodes.

parents

Return parent commits.

paths

Return all paths in the commit.

removed_paths

Return all paths removed in the commit.

submodules

Proxy to client submodules.

to_yaml()[source]

Write an instance to the referenced YAML file.

class renku.core.models.provenance.activities.ProcessRun(*, commit=None, client=None, path=None, label=NOTHING, project: renku.core.models.projects.Project = None, id=None, message=NOTHING, was_informed_by=NOTHING, part_of=None, invalidated=None, influenced=NOTHING, started_at_time=NOTHING, ended_at_time=NOTHING, agents=NOTHING, generated=None, association=None, annotations=None, qualified_usage=None)[source]

A process run is a particular execution of a Process description.

Method generated by attrs for class ProcessRun.

add_annotations(annotations)[source]

Adds annotations from an external tool.

as_jsonld()[source]

Create JSON-LD.

default_agents()

Set person agent to be the author of the commit.

default_ended_at_time()

Configure calculated properties.

default_generated()[source]

Create default generated.

default_id()

Configure calculated ID.

default_influenced()

Calculate default values.

default_invalidated()

Entities invalidated by this Action.

default_label()

Generate a default label.

default_message()

Generate a default message.

default_reference()

Create a default reference path.

default_started_at_time()

Configure calculated properties.

default_was_informed_by()

List parent actions.

classmethod from_jsonld(data, client=None, commit=None)[source]

Create an instance from JSON-LD data.

classmethod from_run(run, client, path, commit=None, subprocess_index=None, update_commits=False)[source]

Convert a Run to a ProcessRun.

classmethod from_yaml(path, client=None, commit=None)

Return an instance from a YAML file.

classmethod generate_id(commitsha)

Calculate action ID.

get_output_paths()

Gets all output paths generated by this run.

nodes

Return topologically sorted nodes.

parents

Return parent commits.

paths

Return all paths in the commit.

plugin_annotations()[source]

Adds Annotation``s from plugins to a ``ProcessRun.

removed_paths

Return all paths removed in the commit.

submodules

Proxy to client submodules.

to_yaml()[source]

Write an instance to the referenced YAML file.

class renku.core.models.provenance.activities.WorkflowRun(*, commit=None, client=None, path=None, label=NOTHING, project: renku.core.models.projects.Project = None, id=None, message=NOTHING, was_informed_by=NOTHING, part_of=None, invalidated=None, influenced=NOTHING, started_at_time=NOTHING, ended_at_time=NOTHING, agents=NOTHING, generated=None, association=None, annotations=None, qualified_usage=None, processes=NOTHING)[source]

A workflow run typically contains several subprocesses.

Method generated by attrs for class WorkflowRun.

add_annotations(annotations)

Adds annotations from an external tool.

as_jsonld()[source]

Create JSON-LD.

default_agents()

Set person agent to be the author of the commit.

default_ended_at_time()

Configure calculated properties.

default_generated()

Create default generated.

default_id()

Configure calculated ID.

default_influenced()

Calculate default values.

default_invalidated()

Entities invalidated by this Action.

default_label()

Generate a default label.

default_message()

Generate a default message.

default_reference()

Create a default reference path.

default_started_at_time()

Configure calculated properties.

default_was_informed_by()

List parent actions.

classmethod from_jsonld(data, client=None, commit=None)[source]

Create an instance from JSON-LD data.

classmethod from_run(run, client, path, commit=None, update_commits=False)[source]

Convert a Run to a WorkflowRun.

classmethod from_yaml(path, client=None, commit=None)

Return an instance from a YAML file.

classmethod generate_id(commitsha)

Calculate action ID.

get_output_paths()

Gets all output paths generated by this run.

nodes

Yield all graph nodes.

parents

Return parent commits.

paths

Return all paths in the commit.

plugin_annotations()

Adds Annotation``s from plugins to a ``ProcessRun.

removed_paths

Return all paths removed in the commit.

submodules

Proxy to client submodules.

subprocesses

Subprocesses of this WorkflowRun.

to_yaml()[source]

Write an instance to the referenced YAML file.

Entities

class renku.core.models.entities.Entity(*, commit=None, client=None, path=None, id=None, label=NOTHING, project: renku.core.models.projects.Project = None, parent=None)[source]

Represent a data value or item.

Method generated by attrs for class Entity.

default_id()

Configure calculated ID.

default_label()

Generate a default label.

entities

Yield itself.

classmethod from_revision(client, path, revision='HEAD', parent=None, find_previous=True, **kwargs)[source]

Return dependency from given path and revision.

parent

Return the parent object.

set_client(client)[source]

Sets the clients on this entity.

submodules

Proxy to client submodules.

class renku.core.models.entities.Collection(*, commit=None, client=None, path=None, id=None, label=NOTHING, project: renku.core.models.projects.Project = None, parent=None, members=None)[source]

Represent a directory with files.

Method generated by attrs for class Collection.

default_id()

Configure calculated ID.

default_label()

Generate a default label.

default_members()[source]

Generate default members as entities from current path.

entities

Recursively return all files.

classmethod from_revision(client, path, revision='HEAD', parent=None, find_previous=True, **kwargs)

Return dependency from given path and revision.

parent

Return the parent object.

set_client(client)[source]

Sets the clients on this entity.

submodules

Proxy to client submodules.

Agents

class renku.core.models.provenance.agents.Person(*, client=None, name, email=None, label=NOTHING, affiliation=None, alternate_name=None, id=None)[source]

Represent a person.

Method generated by attrs for class Person.

check_email(attribute, value)[source]

Check that the email is valid.

default_id()[source]

Set the default id.

default_label()[source]

Set the default label.

classmethod from_commit(commit)[source]

Create an instance from a Git commit.

classmethod from_dict(obj)[source]

Create and instance from a dictionary.

classmethod from_git(git)[source]

Create an instance from a Git repo.

classmethod from_jsonld(data)[source]

Create an instance from JSON-LD data.

classmethod from_string(string)[source]

Create an instance from a ‘Name <email>’ string.

full_identity

Return name, email, and affiliation.

short_name

Gives full name in short form.

class renku.core.models.provenance.agents.SoftwareAgent(*, label, id)[source]

Represent executed software.

Method generated by attrs for class SoftwareAgent.

as_jsonld()[source]

Create JSON-LD.

classmethod from_commit(commit)[source]

Create an instance from a Git commit.

classmethod from_jsonld(data)[source]

Create an instance from JSON-LD data.

Relations

class renku.core.models.provenance.qualified.Usage(*, entity, role=None, id=None)[source]

Represent a dependent path.

Method generated by attrs for class Usage.

as_jsonld()[source]

Create JSON-LD.

classmethod from_jsonld(data)[source]

Create an instance from JSON-LD data.

classmethod from_revision(client, path, revision='HEAD', **kwargs)[source]

Return dependency from given path and revision.

class renku.core.models.provenance.qualified.Generation(entity, role=None, *, activity=None, id=NOTHING)[source]

Represent an act of generating a file.

Method generated by attrs for class Generation.

activity

Return the activity object.

as_jsonld()[source]

Create JSON-LD.

default_id()[source]

Configure calculated ID.

classmethod from_jsonld(data)[source]

Create an instance from JSON-LD data.