Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Emit userEmail in workflow-metadata.json generated by tw runs dump #390

Open
ejseqera opened this issue Mar 5, 2024 · 0 comments
Open
Milestone

Comments

@ejseqera
Copy link
Member

ejseqera commented Mar 5, 2024

Related to #361, it would be helpful to output the userEmail into the workflow-metadata.json file generated by running tw runs dump.

Current behaviour

Running tw runs dump emits a workflow-metadata.json file that will contain the userId but in order to determine who the user is tied to, this id has to be referenced back to the output of tw -o json members list -o <org> to retriever userName and email:

{
  "pipelineId" : 88330947242108,
  "workspaceId" : 162690105070735,
  "workspaceName" : "testing",
  "userId" : 10273,
  "runUrl" : "https://tower.nf/orgs/scidev/workspaces/testing/watch/4TUilc62wiW0Lj"
}

Desired behaviour

The workflow-metadata.json should also include email at the minimum, to more easily identify the user who had kicked off the run without having to run an additional CLI command. For example:

{
  "pipelineId" : 88330947242108,
  "workspaceId" : 162690105070735,
  "workspaceName" : "testing",
  "userId" : 10273,
  "userName": "esha-joshi",
  "email": "esha.joshi@seqera.io",
  "runUrl" : "https://tower.nf/orgs/scidev/workspaces/testing/watch/4TUilc62wiW0Lj"
}

Use Case

Users of the CLI are taking the metadata generated from the tw runs dump command and feeding it into downstream tools/platforms to aggregate statistics for runs, tie runs to their internal LIMS databases, and generate dashboards. Emails serve as a more effective method for associating metadata to users because they typically used for SSO across various platforms, in contrast to usernames that may be ambiguous and vary from one platform to another.

@mbosio85 mbosio85 added this to the v1.0.0 milestone Apr 10, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

3 participants