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

Save warning due unresolved linter issues #11757

Merged

Conversation

SHKnudsen
Copy link
Contributor

Purpose

This PR adds a new dialog when a user saves the graph while there are unresolved issues in the graph. The Dialog gives two options either continue to save the graph with the issues or cancel the save and show the Graph Status extension.

For unit test purposes a new event SaveWarningOnUnresolvedIssuesShows has been added, this is only meant to be used for the tests to verify that this dialog actually shows. Because the GenericTaskDialog is not owned by the DynamoWindow we cant verify that its opened that way, hence the need for adding this event.

GraphTypeIssueWarningDialog

SaveWarnings_v2

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.
  • This PR modifies some build requirements and the readme is updated

Reviewers

@saintentropy @BogdanZavu @nate-peters

FYIs

@mjkkirschner

@mjkkirschner
Copy link
Member

I imagine this will break existing UIAutomation and other serial tests if not normally disabled during testmode - is it?

@mjkkirschner
Copy link
Member

Are there plans to add this idea of "graph type" to primer? @Amoursol @saintentropy @Jingyi-Wen - If I was not aware of GDIR I doubt I would have any idea what this was message was referring to.

@SHKnudsen
Copy link
Contributor Author

I imagine this will break existing UIAutomation and other serial tests if not normally disabled during testmode - is it?

@mjkkirschner if in testmode the dialog is showed as a modeless dialog, will that be enough to not break the UIAutomation tests?
https://github.com/DynamoDS/Dynamo/pull/11757/files#diff-66aa776eedd00c3ed606e067aa057cee77527430d1ab1ab8a749c42b896a58e5R1943

@Amoursol
Copy link
Contributor

Are there plans to add this idea of "graph type" to primer? @Amoursol @saintentropy @Jingyi-Wen - If I was not aware of GDIR I doubt I would have any idea what this was message was referring to.

No plans from the Morpheus/Turbo side as it stands, albeit we do have plans to update the Primer it it's entirety after the Visual Refresh project lands. @saintentropy - any scope on this side from your end in addition to the Repo / Wiki?


var dialog = new GenericTaskDialog(args);

if (DynamoModel.IsTestMode)
Copy link
Contributor

Choose a reason for hiding this comment

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

Overall I think this looks good.
For the test I'm ok with it as it is but I'm not sure how much value we get since we're not going through the same route when user is at the helm and we're adding some code to make that happen.
How about we just test if the LinterView has opened when there are issues and cancel was pressed ?
I'm thinking to do this : we trigger an event for the cancel action for which we have a handler that will check issues and will open linter view if it has to ( this event will be triggered from both user mode and test mode ).
And this would be the testable part, we will just raise this event from the test, no pressing on Cancel button since we don't have access/can't control it.

@saintentropy
Copy link
Contributor

@mjkkirschner UI tests pass in the self service. Shouldn't be affected.

@saintentropy saintentropy merged commit 79e76af into DynamoDS:master Jun 21, 2021
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.

5 participants