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

[KED-2831] Fix focus mode error when switching pipelines #553

Merged
merged 12 commits into from
Sep 3, 2021

Conversation

studioswong
Copy link
Contributor

Description

related ticket: https://jira.quantumblack.com/secure/RapidBoard.jspa?rapidView=525&projectKey=KED&view=detail&selectedIssue=KED-2831

This is to fix the error thrown when switching between pipelines while in focus mode.

Development notes

The bug is caused by the persistence of the focus mode state while switching between pipelines - the problem will be solved by resetting the value of the selected focus mode modular pipeline when switching between pipelines.

I have added the dispatch of the relevant action, as well as the relevant test to ensure this action to reset the focus mode state gets dispatched everytime we switch between pipelines.

QA notes

select a modular pipeline to be under focus mode, and try switching between pipelines. The error should not happen again.

Checklist

  • Read the contributing guidelines
  • Opened this PR as a 'Draft Pull Request' if it is work-in-progress
  • Updated the documentation to reflect the code changes
  • Added new entries to the RELEASE.md file
  • Added tests to cover my changes

Legal notice

  • I acknowledge and agree that, by checking this box and clicking "Submit Pull Request":

  • I submit this contribution under the Apache 2.0 license and represent that I am entitled to do so on behalf of myself, my employer, or relevant third parties, as applicable.

  • I certify that (a) this contribution is my original creation and / or (b) to the extent it is not my original creation, I am authorised to submit this contribution on behalf of the original creator(s) or their licensees.

  • I certify that the use of this contribution as authorised by the Apache 2.0 license does not violate the intellectual property rights of anyone else.

Copy link
Collaborator

@limdauto limdauto left a comment

Choose a reason for hiding this comment

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

This LGTM as a fix but I wonder if we can do something at a higher level, e.g. parameterise the state store based on the selected registered pipelines?

pipeline_a: <state>
pipeline_b: <state>
__default__: <state>

@studioswong
Copy link
Contributor Author

This LGTM as a fix but I wonder if we can do something at a higher level, e.g. parameterise the state store based on the selected registered pipelines?

pipeline_a: <state>
pipeline_b: <state>
__default__: <state>

Heya that is an interesting suggestion! yea I see what you mean - Saving all the loaded pipeline data on a higher level in the state could even help us preserve the individual state of each pipeline ( e.g selected focus mode, etc), great idea.

I think we haven't set it up this way previously as there isn't any particular need to preserve the app state of each pipeline, but now that we are implementing more features ( i.e experiment tracking) that suggests more complicated individual states for each pipelines that would need to be preserved, it makes sense for us to revisit the data structure of our store. This would definitely require quite a bit of rewrite, but I can factor that in for the FE architecture spike and make a new ticket for implementing this ( if needed)?

@studioswong studioswong merged commit b101d61 into main Sep 3, 2021
@studioswong studioswong deleted the fix/KED-2831-fix-focus-mode-switching-pipelines branch September 3, 2021 14:51
@limdauto
Copy link
Collaborator

limdauto commented Sep 3, 2021

@studioswong 👍 agreed. Let's track this. I really want to move away from a single state store at some point.

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.

2 participants