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

Allow experiments table to sort by last run started #2890

Merged

Conversation

dpanshug
Copy link
Contributor

@dpanshug dpanshug commented Jun 7, 2024

Closes: RHOAIENG-7715

Description

Added new column in Experiments table for last run started.

Screenshot 2024-06-12 at 4 51 50 PM

How Has This Been Tested?

Go to Experiments page and you can find the new column added.

Test Impact

Request review criteria:

Self checklist (all need to be checked):

  • The developer has manually tested the changes and verified that the changes work
  • Commits have been squashed into descriptive, self-contained units of work (e.g. 'WIP' and 'Implements feedback' style messages have been removed)
  • Testing instructions have been added in the PR body (for PRs involving changes that are not immediately obvious).
  • The developer has added tests or explained why testing cannot be added (unit or cypress tests for related changes)

If you have UI changes:

  • Included any necessary screenshots or gifs if it was a UI change.
  • Included tags to the UX team if it was a UI/UX change (find relevant UX in the SMEs section).

After the PR is posted & before it merges:

  • The developer has tested their solution on a cluster by using the image produced by the PR to main

@yannnz

@openshift-ci openshift-ci bot requested review from DaoDaoNoCode and lucferbux June 7, 2024 17:02
@dpanshug dpanshug changed the title Allow experiments table to sort by last run started [WIP] Allow experiments table to sort by last run started Jun 7, 2024
@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress This PR is in WIP state label Jun 7, 2024
@dpanshug
Copy link
Contributor Author

dpanshug commented Jun 7, 2024

Is blocked by RHOAIENG-7692

@dpanshug dpanshug force-pushed the experiment-lastrun branch 2 times, most recently from 51ca864 to 7714259 Compare June 7, 2024 17:05
Copy link

codecov bot commented Jun 7, 2024

Codecov Report

Attention: Patch coverage is 83.33333% with 1 line in your changes missing coverage. Please review.

Project coverage is 78.65%. Comparing base (74513a0) to head (56108da).

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2890      +/-   ##
==========================================
+ Coverage   78.63%   78.65%   +0.01%     
==========================================
  Files        1120     1120              
  Lines       23772    23778       +6     
  Branches     5984     5986       +2     
==========================================
+ Hits        18693    18702       +9     
+ Misses       5079     5076       -3     
Files Coverage Δ
...d/src/concepts/pipelines/content/tables/columns.ts 55.55% <ø> (ø)
...s/content/tables/experiment/ExperimentTableRow.tsx 100.00% <ø> (ø)
frontend/src/concepts/pipelines/kfTypes.ts 100.00% <ø> (ø)
...ipelines/content/tables/experiment/renderUtils.tsx 88.23% <83.33%> (-2.68%) ⬇️

... and 3 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 74513a0...56108da. Read the comment docs.

@dpanshug
Copy link
Contributor Author

I've included the last_run_created_at field for the sorting in this PR. Also I've noticed that this field has been added to the experiment schema in the backend PR, so I've modified the previous functionality, which calculated the last run using the usePipelineRunsByExperiment function, to now directly use the experiment.last_run_created_at field.

Till the backend PR is merged, Last run started column will only show "Just now".

@dpanshug dpanshug force-pushed the experiment-lastrun branch from 7714259 to cb95e12 Compare June 11, 2024 15:27
@dpanshug dpanshug changed the title [WIP] Allow experiments table to sort by last run started Allow experiments table to sort by last run started Jun 11, 2024
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress This PR is in WIP state label Jun 11, 2024
@dpanshug dpanshug requested a review from Gkrumbach07 June 11, 2024 15:28
@dpanshug
Copy link
Contributor Author

dpanshug commented Jun 11, 2024

@Gkrumbach07 should we mark on this on hold, till opendatahub-io/data-science-pipelines#52 merges?

@Gkrumbach07
Copy link
Member

@dpanshug Looks like it merged. i am testing this with the changes

@Gkrumbach07
Copy link
Member

tested and works. there is one thing we may or may not need to handle. the backend will return "1970-01-01T00:00:00Z" on a new experiment. So we may have to handle this edge case, or they may fix it. regardless on an invalid param can you make the value -

@Gkrumbach07
Copy link
Member

OK update from backend. Lets render "1970-01-01T00:00:00Z" and "" (empty string) as -. otherwise render as date

@dpanshug dpanshug force-pushed the experiment-lastrun branch from cb95e12 to dafa951 Compare June 12, 2024 10:23
@dpanshug dpanshug force-pushed the experiment-lastrun branch from dafa951 to 56108da Compare June 12, 2024 11:23
Copy link
Member

@Gkrumbach07 Gkrumbach07 left a comment

Choose a reason for hiding this comment

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

awesome thanks

/lgtm
/approve

Copy link
Contributor

openshift-ci bot commented Jun 12, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Gkrumbach07

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot openshift-merge-bot bot merged commit 6b6e9d8 into opendatahub-io:main Jun 12, 2024
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants