Skip to content

Conversation

@reddyashish
Copy link
Contributor

@reddyashish reddyashish commented Jan 7, 2020

Purpose

This PR is to close the workspace references extension tab when the workspace is closed so that when the user reopens the graph with no missing dependencies, the extension is hidden. It will only be shown when the workspace has missing dependencies.

Closing

Declarations

Check these if you believe they are true

  • The codebase is in a better state after this PR
  • Is documented according to the standards
  • The level of testing this PR includes is appropriate
  • User facing strings, if any, are extracted into *.resx files
  • All tests pass using the self-service CI.
  • Snapshot of UI changes, if any.
  • Changes to the API follow Semantic Versioning and are documented in the API Changes document.

Reviewers

@mjkkirschner @QilongTang @aparajit-pratap

…sion.

This will handle the case when the workspace is closed.
@reddyashish reddyashish changed the title Event to handle the close operation of the Event to handle the close operation of the workspace references extension Jan 7, 2020
@reddyashish
Copy link
Contributor Author

Started the self-serve run with these changes

@mjkkirschner
Copy link
Member

mjkkirschner commented Jan 7, 2020

@reddyashish - actually I have been thinking about this a bit more:

This seems weirdly specific for the WorkspaceReferences Extension to have code that lives in homeworkspaceModel and DynamoView...

Instead, what about just adding some code to the WorkspaceReferences Extension to watch for the close or clear events on the current homework space and close when that occur, I think that is a better design if this functionality is only being implemented for this extension thats where I would look for it - on the other hand if this is a general implementation for all extensions then it belongs where you put it.

I agree in general that this behavior is actually not desirable for all extensions, so my vote would be to implement this as part of the extension logic, and not as part of DynamoCore.

(if you have to add new events to homeWorkspace - like Cleared - then do that.)

@reddyashish
Copy link
Contributor Author

@mjkkirschner made the necessary code changes. Running the self-serve now and will add some tests to this.

@QilongTang
Copy link
Contributor

I have some code changes touching same files in #10279. It maybe good for us to merge in turns to avoid conflicts

@mjkkirschner
Copy link
Member

@reddyashish I see @QilongTang renamed the method already - LGTM - lets just be sure theres no conflicts.

@mjkkirschner mjkkirschner added the LGTM Looks good to me label Jan 9, 2020
@QilongTang
Copy link
Contributor

@reddyashish Sorry for the conflicts! Once that is resolved, you should be good to merge

@reddyashish
Copy link
Contributor Author

@QilongTang @mjkkirschner No worries, thanks for the changes. I will pull in your changes.

@reddyashish
Copy link
Contributor Author

Closing this and opening a new one to resolve the conflicts. #10280

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

LGTM Looks good to me

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants