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

Implement fix for duplicate entries in visualisation list. #5808

Conversation

MichaelMauderer
Copy link
Contributor

@MichaelMauderer MichaelMauderer commented Mar 3, 2023

Pull Request Description

Fixes duplicate entries in the visualization chooser. The issue was caused by entries added twice, once matching the Any type and once matching the concrete type. Closes #5708.

Checklist

Please include the following checklist in your PR:

  • The documentation has been updated if necessary.
  • All code conforms to the
    Scala,
    Java,
    and
    Rust
    style guides.
  • All code has been tested:
    • Unit tests have been written where possible.
    • If GUI codebase was changed: Enso GUI was tested when built using BOTH
      ./run ide build and ./run ide watch.

@MichaelMauderer MichaelMauderer self-assigned this Mar 3, 2023
@MichaelMauderer MichaelMauderer added the CI: No changelog needed Do not require a changelog entry for this PR. label Mar 3, 2023
@MichaelMauderer MichaelMauderer force-pushed the wip/MichaelMauderer/Remove_Duplicate_Entries_From_Default_Visualisations branch from f54017b to b4e2f26 Compare March 3, 2023 15:53
@MichaelMauderer MichaelMauderer marked this pull request as ready for review March 3, 2023 15:58
Comment on lines 73 to 77
for vis in vis_for_any {
if !result.contains(vis) {
result.push(vis.clone_ref());
}
}
Copy link
Contributor

Choose a reason for hiding this comment

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

We may easily speed it up by keeping hash set of paths. AFAIK the path identifies the visualization.

Copy link
Contributor

@farmaazon farmaazon left a comment

Choose a reason for hiding this comment

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

QA green

@MichaelMauderer MichaelMauderer added the CI: Ready to merge This PR is eligible for automatic merge label Mar 7, 2023
@mergify mergify bot merged commit 3c3d1f0 into develop Mar 7, 2023
@mergify mergify bot deleted the wip/MichaelMauderer/Remove_Duplicate_Entries_From_Default_Visualisations branch March 7, 2023 23:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI: No changelog needed Do not require a changelog entry for this PR. CI: Ready to merge This PR is eligible for automatic merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Duplicated entries in visualisations list
2 participants