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

[Staleness] Fix staleness on clock change #7088

Merged
merged 22 commits into from
Oct 4, 2023
Merged

Conversation

khalidadil
Copy link
Contributor

Closes #6339

Describe your changes:

Refactored staleness out of Vue components and into a mixin where possible. Added the function to unsubscribe/resubscribe staleness on clock change, and added a guard to make sure staleness only applied to correct clock.

All Submissions:

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  • Is this change backwards compatible? For example, developers won't need to change how they are calling the API or how they've extended core plugins such as Tables or Plots.

Author Checklist

  • Changes address original issue?
  • Tests included and/or updated with changes?
  • Command line build passes?
  • Has this been smoke tested?
  • Testing instructions included in associated issue OR is this a dependency/testcase change?

Reviewer Checklist

  • Changes appear to address issue?
  • Reviewer has tested changes by following the provided instructions?
  • Changes appear not to be breaking changes?
  • Appropriate automated tests included?
  • Code style and in-line documentation are appropriate?
  • Has associated issue been labelled unverified? (only applicable if this PR closes the issue)
  • Has associated issue been labelled bug? (only applicable if this PR is for a bug fix)

@deploysentinel
Copy link

deploysentinel bot commented Sep 25, 2023

Current Playwright Test Results Summary

✅ 14 Passing - ⚠️ 1 Flaky

Run may still be in progress, this comment will be updated as current testing workflow or job completes...

(Last updated on 10/04/2023 08:06:31pm UTC)

Run Details

Running Workflow e2e-couchdb on Github Actions

Commit: d89e1a9

Started: 10/04/2023 08:03:26pm UTC

⚠️ Flakes

📄   functional/plugins/displayLayout/displayLayout.e2e.spec.js • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
Display Layout When multiple plots are contained in a layout, we only ask for annotations once @couchdb
Retry 1Initial Attempt
2.13% (1) 1 / 47 run
failed over last 7 days
25.53% (12) 12 / 47 runs
flaked over last 7 days

View Detailed Build Results


Current Playwright Test Results Summary

✅ 141 Passing - ⚠️ 2 Flaky

Run may still be in progress, this comment will be updated as current testing workflow or job completes...

(Last updated on 10/04/2023 08:06:31pm UTC)

Run Details

Running Job e2e-stable on CircleCI

Commit: d89e1a9

Started: 10/04/2023 07:47:21pm UTC

⚠️ Flakes

📄   functional/plugins/plot/logPlot.e2e.spec.js • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
Log plot tests Log Plot ticks are functionally correct in regular and log mode and after refresh
Retry 1Initial Attempt
0% (0) 0 / 97 runs
failed over last 7 days
32.99% (32) 32 / 97 runs
flaked over last 7 days

📄   functional/plugins/notebook/notebookSnapshots.e2e.spec.js • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
Snapshot image tests Can drop an image onto a notebook and create a new entry
Retry 1Initial Attempt
17.71% (17) 17 / 96 runs
failed over last 7 days
54.17% (52) 52 / 96 runs
flaked over last 7 days

View Detailed Build Results


@codecov
Copy link

codecov bot commented Sep 25, 2023

Codecov Report

Merging #7088 (d89e1a9) into master (5eed5de) will increase coverage by 0.18%.
The diff coverage is 66.44%.

@@            Coverage Diff             @@
##           master    #7088      +/-   ##
==========================================
+ Coverage   55.54%   55.72%   +0.18%     
==========================================
  Files         650      650              
  Lines       26102    26092      -10     
  Branches     2549     2519      -30     
==========================================
+ Hits        14498    14540      +42     
+ Misses      10900    10849      -51     
+ Partials      704      703       -1     
Flag Coverage Δ *Carryforward flag
e2e-full 41.92% <ø> (-0.02%) ⬇️ Carriedforward from ea4c86a
e2e-stable 57.13% <71.18%> (-0.07%) ⬇️
unit 49.35% <59.21%> (+0.22%) ⬆️

*This pull request uses carry forward flags. Click here to find out more.

Files Coverage Δ
src/plugins/condition/components/ConditionSet.vue 0.00% <ø> (ø)
src/plugins/gauge/components/Gauge.vue 61.71% <ø> (-1.08%) ⬇️
src/plugins/plot/legend/PlotLegendItemExpanded.vue 66.17% <100.00%> (-1.52%) ⬇️
src/ui/components/ObjectView.vue 43.93% <ø> (-0.29%) ⬇️
src/utils/staleness.js 95.65% <100.00%> (+0.41%) ⬆️
...plugins/displayLayout/components/TelemetryView.vue 2.47% <0.00%> (-0.07%) ⬇️
src/plugins/plot/Plot.vue 68.51% <66.66%> (+10.68%) ⬆️
...rc/plugins/plot/legend/PlotLegendItemCollapsed.vue 65.07% <0.00%> (-1.59%) ⬇️
.../plugins/condition/criterion/TelemetryCriterion.js 73.22% <50.00%> (-1.57%) ⬇️
src/plugins/telemetryTable/TelemetryTable.js 85.26% <89.47%> (+3.54%) ⬆️
... and 6 more

... and 6 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 5eed5de...d89e1a9. Read the comment docs.

@khalidadil khalidadil added the pr:e2e:couchdb npm run test:e2e:couchdb label Sep 25, 2023
@github-actions github-actions bot removed the pr:e2e:couchdb npm run test:e2e:couchdb label Sep 25, 2023
@khalidadil khalidadil changed the title Bugfix/issue 6339 v3 [Staleness] Fix staleness on clock change Sep 25, 2023
@khalidadil khalidadil added the pr:e2e:couchdb npm run test:e2e:couchdb label Sep 26, 2023
@github-actions github-actions bot removed the pr:e2e:couchdb npm run test:e2e:couchdb label Sep 26, 2023
@ozyx ozyx added this to the Target:3.1.0 milestone Oct 2, 2023
@khalidadil khalidadil added the pr:e2e:couchdb npm run test:e2e:couchdb label Oct 3, 2023
@github-actions github-actions bot removed the pr:e2e:couchdb npm run test:e2e:couchdb label Oct 3, 2023
@khalidadil khalidadil requested a review from jvigliotta October 4, 2023 13:04
@khalidadil khalidadil added the pr:e2e:couchdb npm run test:e2e:couchdb label Oct 4, 2023
@github-actions github-actions bot removed the pr:e2e:couchdb npm run test:e2e:couchdb label Oct 4, 2023
@khalidadil khalidadil added the pr:e2e:couchdb npm run test:e2e:couchdb label Oct 4, 2023
@github-actions github-actions bot removed the pr:e2e:couchdb npm run test:e2e:couchdb label Oct 4, 2023
@khalidadil khalidadil requested a review from jvigliotta October 4, 2023 20:08
Copy link
Contributor

@jvigliotta jvigliotta left a comment

Choose a reason for hiding this comment

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

Nice work! The refactor looks great and moves a lot of the duplication out. Well done!

@jvigliotta jvigliotta merged commit 734a8dd into master Oct 4, 2023
@jvigliotta jvigliotta deleted the bugfix/issue-6339-v3 branch October 4, 2023 20:39
khalidadil added a commit that referenced this pull request Oct 4, 2023
* Update staleness mixin
* Fix listeners and add guard
* Add check to make sure staleness only shows for correct clock
* Add guard for time api
* Cleanup the setting of isStale in ObjectView
* Cleanup use of combinedKey on LadTableSet
jvigliotta pushed a commit that referenced this pull request Oct 4, 2023
[Staleness] Fix staleness on clock change (#7088)

* Update staleness mixin
* Fix listeners and add guard
* Add check to make sure staleness only shows for correct clock
* Add guard for time api
* Cleanup the setting of isStale in ObjectView
* Cleanup use of combinedKey on LadTableSet
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.

[Staleness] Switching between clock modes incorrectly persists the current staleness state
3 participants