-
Notifications
You must be signed in to change notification settings - Fork 636
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
DYN-6719 - show warning when installing, and log when loading a package from 2.x in Dynamo 3.x #15083
Conversation
UI Smoke TestsTest: success. 2 passed, 0 failed. |
Is there a good way to check if a package or it’s deps have binaries ? |
src/DynamoCoreWpf/ViewModels/PackageManager/PackageManagerClientViewModel.cs
Outdated
Show resolved
Hide resolved
src/DynamoCoreWpf/ViewModels/PackageManager/PackageManagerClientViewModel.cs
Outdated
Show resolved
Hide resolved
I think this is a good warning to have. However, I would be curious how this would work with something that may be built for net 4.8, but still works. Extensions technically work this way. (This is how monocle and Rhythm load on the fly). And if that warning shows up in my case, that is kind of lousy because the actual DLLs that I write on runtime are built for the correct frameworks. |
kind of - the |
Hey @johnpierson yep it's a good point, unfortunately AFAIK we can't truly know if a binary targeting .net48 will work correctly on the .net8.0 runtime without doing a lot of inspection for references and even then we might still get it wrong. I have two suggestions though:
|
turns out Roberto solved this a while ago for guided tour functionality and we can just reuse the custom rich text box control he added there. |
also fix tooltip bug
The only possible improvement I can think of would be for the wording “This package or one… use an older version of dynamo than the one you are using”. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One comment then Lgtm
Suggested rephrase of warning message: Package may not work in this version of Dynamo This package or one of its dependencies were created for a previous version of Dynamo. It may not work in this version. Do you want to continue? Learn more |
MessageBoxResult IMessageBox.Show(Window owner, string msg, string title, bool showRichTextBox, MessageBoxButton button, MessageBoxImage img) | ||
{ | ||
return DynamoMessageBox.Show(owner,msg, title, showRichTextBox, button, img); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for both the owner
and showRichTextBox
param.
Since this type and interface are really internal
we can probably just delete all these overloads and simplify whenever we want.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ugh well, just to correct this a bit -
the interface is internal, but the MessageBoxService
and these Show
methods implementing that interface are public - though the whole thing is in DynamoCoreWPF.dll, so I think it requires just a bit more thinking before we refactor this.
…ge from 2.x in Dynamo 3.x (DynamoDS#15083) tests pass - merging. https://master-15.jenkins.autodesk.com/view/DYN/job/DYN-DevCI_Self_Service/1423/ (filterFrozentest) is marked failure on master.
* test * DYN-6719 - show warning when installing, and log when loading a package from 2.x in Dynamo 3.x (#15083) tests pass - merging. https://master-15.jenkins.autodesk.com/view/DYN/job/DYN-DevCI_Self_Service/1423/ (filterFrozentest) is marked failure on master.
Purpose
Since packages that were published from Dynamo 1.x or 2.x likely target net framework instead of .NET8 - we'll raise a warning if versions of those packages are installed. At load time, we'll just log some information without alerting the user, this will be useful for devs when inspecting logs - it's possible that a package may load successfully but have strange behavior later.
- [ ] One improvement we could make here is to not raise these warnings for packages that do not contain any .Net binaries. (ie those that only contain dyf files) I was not sure about this, what do reviewers think?This PR also fixes a really annoying bug where Dynamo's custom message box type had a tooltip show up with no content.
Declarations
Check these if you believe they are true
*.resx
filesRelease Notes
show warnings when installing packages into Dynamo 3.x that were published from Dynamo < 3.x
Reviewers