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

Compliance Update and Enable Update Panels #310

Merged
merged 29 commits into from
Feb 21, 2020

Conversation

rwemay
Copy link
Member

@rwemay rwemay commented Feb 3, 2020

NOTE: Depends on

Issues addressed by this PR

Closes #308
Closes #301
Closes #250
Closes #184
Closes #249
Closes #319
Closes #318
Closes #321
Closes #322

Test files

Test files and models

Changelog

Additional comments

@rwemay rwemay added the status:do-not-merge For instance, test PR, for discussion, or dependant PRs not ready for merge label Feb 4, 2020
@rwemay
Copy link
Member Author

rwemay commented Feb 4, 2020

@IsakNaslundBh , @kThorsager , @alelom this is now getting there. I've fixed a few things related to panel update, specifically the support/releases for the edges, which were not properly implemented before. One thing to check before fully test/merge:

  • I've added a call to Update methods for panel edge supports and releases - so if the label already exists in Robot, the properties of the label will be updated (supported/released directions). I'm not sure if this is the intention of the update methods - to update dependent properties, but if it is I think we need a different solution here. The way I've currently written, this will effectively be re-writing the same properties many times.
  • Assuming we should be updating dependent properties, I need to implement something for other properties - e.g. panel thickness, if the name is the same.
  • I'm not sure how the adapter is handling checking uniqueness of properties for similar named objects - so for example, if someone pushes lots of bars, with releases, and the releases have the same name, but different release directions, presumably all bars will have releases based on the first one pushed?

More questions than answers :) I'm off tomorrow, so catch up Thursday/later this week. Either way not one to rush through given extent of change necessary.

Copy link
Contributor

@IsakNaslundBh IsakNaslundBh left a comment

Choose a reason for hiding this comment

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

Really nice to get this in!

Some comments on some things that will need updating. Have just read the code, no tests yet.

/**** Protected Methods ****/
/***************************************************/

protected override bool UpdateOnly<T>(IEnumerable<T> panels, string tag = "", ActionConfig actionConfig = null)
Copy link
Contributor

Choose a reason for hiding this comment

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

Would not override this method, but just change it do an Update method that then can be dynamically called by the IUpdate mehtod. (similar principle as what we do with the Create)

By overriding this method UpdateOnly will only work for panels, but no other objects.

Copy link
Member Author

Choose a reason for hiding this comment

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

Sorry missed that one... was still getting to grips with new adapter. Updated now and reran just to check - all ok. Have you seen my comments in message above? Line 165 and 193 in this cs file are relevant. I'm not sure it's 'correct' to be calling update on properties of dependent objects, and if it is, I don't think this approach is sustainable (and will have a big performance hit as it scales).

@IsakNaslundBh IsakNaslundBh dismissed their stale review February 7, 2020 08:35

Update fixed

IsakNaslundBh
IsakNaslundBh previously approved these changes Feb 7, 2020
Copy link
Contributor

@IsakNaslundBh IsakNaslundBh left a comment

Choose a reason for hiding this comment

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

Testing if rebase possible

@IsakNaslundBh IsakNaslundBh dismissed their stale review February 7, 2020 08:36

Dismissing test review

@IsakNaslundBh IsakNaslundBh self-requested a review February 7, 2020 08:37
@rwemay rwemay force-pushed the Robot_Toolkit-#Issue308-UpdateOnlyMethods branch from 1c2c44c to 1b8a57c Compare February 14, 2020 11:52
@rwemay rwemay added size:M Measured in hours and removed status:do-not-merge For instance, test PR, for discussion, or dependant PRs not ready for merge labels Feb 14, 2020
@rwemay rwemay self-assigned this Feb 14, 2020
@rwemay
Copy link
Member Author

rwemay commented Feb 14, 2020

@IsakNaslundBh , I've tidied up this PR and network graph and I think/hope is ready for testing. Maybe one for us to talk/work though? Essentially final change is removing the auto-generated new properties when a named property (support/release) already exists, but returning a warning if we modify the named property in the model. Eventually I'd like to return 'one' warning to 'check push report' down the line - once we've built out the push report (returned as part of the 'success').

image

@FraserGreenroyd
Copy link
Contributor

/azp run Robot_Toolkit.CheckCompliance

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Contributor

@FraserGreenroyd FraserGreenroyd left a comment

Choose a reason for hiding this comment

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

I've had a look at the compliance report on this and am requesting changes because there are a few files which do not appear to conform to current guidelines. Please review the report on the details for more information or reach out if anything is unclear 😄

Also, this PR needs an appropriate label (bug, feature, compliance, etc.) in addition to the size for the change log please.

@rwemay rwemay added status:do-not-merge For instance, test PR, for discussion, or dependant PRs not ready for merge type:feature New capability or enhancement labels Feb 16, 2020
@rwemay
Copy link
Member Author

rwemay commented Feb 16, 2020

Thanks @FraserGreenroyd , we were going to hold off the compliance updates for this/do it gradually. I see the tests are failing because we done a first pass (move cs files). Will see if I can try and add compliance changes too.

@IsakNaslundBh I've found another issue with the adapter update cycle, so have added do not merge label again... sorry. Hopefully will fix tomorrow.

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@rwemay
Copy link
Member Author

rwemay commented Feb 20, 2020

/azp run Robot_Toolkit.CheckCompliance

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@rwemay
Copy link
Member Author

rwemay commented Feb 21, 2020

/azp run Robot_Toolkit.CheckCompliance

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@rwemay rwemay removed the status:do-not-merge For instance, test PR, for discussion, or dependant PRs not ready for merge label Feb 21, 2020
Copy link
Contributor

@FraserGreenroyd FraserGreenroyd left a comment

Choose a reason for hiding this comment

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

I'm happy with this from a compliance perspective, thanks @rwemay - will allow @IsakNaslundBh the final approval from a functionality perspective 😄

Copy link
Contributor

@IsakNaslundBh IsakNaslundBh left a comment

Choose a reason for hiding this comment

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

Code looks a lot better and all test runs works as good or better than before.

Would say lets get this merged, and if any bugs pop up, lets solve them later (do not think there should be any major induced by this PR)

@IsakNaslundBh
Copy link
Contributor

/azp run Robot_Toolkit.CheckCompliance

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@IsakNaslundBh
Copy link
Contributor

/azp run Robot_Toolkit.CheckInstaller

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@IsakNaslundBh IsakNaslundBh merged commit a924350 into master Feb 21, 2020
@IsakNaslundBh IsakNaslundBh deleted the Robot_Toolkit-#Issue308-UpdateOnlyMethods branch February 21, 2020 15:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment