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: remove tree-item-destroyed event #6856

Merged
merged 3 commits into from
Jul 31, 2023

Conversation

ozyx
Copy link
Contributor

@ozyx ozyx commented Jul 30, 2023

Closes #6838

Describe your changes:

Composition listeners should only be removed if the item has been deleted or its parent has been collapsed. Both are handled by mct-tree already, so doing this additionally when tree-items unmount is redundant.

In addition to that, any time the visibleTreeItems array changes, all tree-items will unmount, so this just doesn't work as intended-- it will unregister all composition listeners whenever the tree changes!

This recently started cropping up because of a typo I had fixed in tree-item.vue, so this was never firing before-- otherwise we would have caught this issue way sooner.

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)

- Composition listeners should only be removed if the item has been deleted or its parent has been collapsed. Both are handled by `mct-tree` already, so doing this additionally when tree-items unmount is redundant.

- In addition to that, any time the `visibleTreeItems` array changes, all tree-items will unmount, so this just doesn't work as intended-- it will unregister all composition listeners whenever the tree changes!
@ozyx ozyx added this to the Target:3.0.0 milestone Jul 30, 2023
@deploysentinel
Copy link

deploysentinel bot commented Jul 30, 2023

Current Playwright Test Results Summary

✅ 14 Passing

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

(Last updated on 07/30/2023 06:51:50am UTC)

Run Details

Running Workflow e2e-couchdb on Github Actions

Commit: ccc96e5

Started: 07/30/2023 06:49:57am UTC

View Detailed Build Results


Current Playwright Test Results Summary

✅ 131 Passing - ⚠️ 3 Flaky

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

(Last updated on 07/30/2023 06:51:50am UTC)

Run Details

Running Job e2e-stable on CircleCI

Commit: ccc96e5

Started: 07/30/2023 05:51:31am UTC

⚠️ Flakes

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

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
Basic Condition Set Use ConditionSet should output blank instead of the default value
Retry 1Initial Attempt
9.72% (7) 7 / 72 runs
failed over last 7 days
33.33% (24) 24 / 72 runs
flaked over last 7 days

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

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
Restricted Notebook with a page locked and with an embed @addinit Allows embeds to be deleted if page unlocked @addinit
Retry 1Initial Attempt
0% (0) 0 / 62 runs
failed over last 7 days
20.97% (13) 13 / 62 runs
flaked over last 7 days

📄   functional/planning/timelist.e2e.spec.js • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
Time List Create a Time List, add a single Plan to it and verify all the activities are displayed with no milliseconds
Retry 1Initial Attempt
4.35% (4) 4 / 92 runs
failed over last 7 days
7.61% (7) 7 / 92 runs
flaked over last 7 days

View Detailed Build Results


- Use keyboard gestures to navigate
@codecov
Copy link

codecov bot commented Jul 30, 2023

Codecov Report

Merging #6856 (ccc96e5) into master (3ae14cf) will decrease coverage by 0.05%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #6856      +/-   ##
==========================================
- Coverage   48.27%   48.22%   -0.05%     
==========================================
  Files         643      643              
  Lines       25619    25618       -1     
  Branches     2507     2507              
==========================================
- Hits        12367    12355      -12     
- Misses      12761    12785      +24     
+ Partials      491      478      -13     
Flag Coverage Δ *Carryforward flag
e2e-full 42.00% <ø> (ø) Carriedforward from a49457a
e2e-stable 56.94% <ø> (+1.88%) ⬆️
unit 38.69% <ø> (-0.82%) ⬇️

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

Files Changed Coverage Δ
src/ui/layout/mct-tree.vue 21.39% <ø> (ø)
src/ui/layout/tree-item.vue 0.00% <ø> (ø)

... and 33 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 3ae14cf...ccc96e5. Read the comment docs.

@ozyx ozyx added the pr:e2e:couchdb npm run test:e2e:couchdb label Jul 30, 2023
@github-actions github-actions bot removed the pr:e2e:couchdb npm run test:e2e:couchdb label Jul 30, 2023
@khalidadil khalidadil merged commit f0ef93d into master Jul 31, 2023
9 checks passed
@khalidadil khalidadil deleted the mct6838-new-items-dont-show-up-in-the-tree branch July 31, 2023 16:57
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.

New items don't show up in the tree unless you expand/collapse the parent
2 participants