-
Notifications
You must be signed in to change notification settings - Fork 319
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
Add a few more fixes for environments #2892
Conversation
@@ -83,24 +84,16 @@ | |||
Grid.Column="2" | |||
Margin="0 0 5 0" | |||
x:Uid="SetupTargetReviewPageComputeSystemVersion" | |||
Visibility="{x:Bind ViewModel.OsName, Mode=OneWay, Converter={StaticResource EmptyObjectToObjectConverter}}" |
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.
I could definitely be misremembering, but have you tested this with both scenarios? I have a vague memory of trying to do something like this and realizing that Collapsed still resolved to "true" or something like that.
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.
Hey yes, I tested both scenarios. The key here is making the OsName = null
in the SetOsNameAsync
method here. Only when the object is null will the UI element be collasped. In the second video at timestamp 0:13 seconds
that shows what happens when OsName is null
. The version text box and the string next to it does not appear. Then in timestamp 0:27 seconds
is what happens when OsName is not null
collection.RemoveAt(i); | ||
} | ||
} | ||
catch (Exception ex) |
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.
If we get an exception, would we still want to try to clear the rest of the collection, or is it not worth it?
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.
I believe it's not worth it, as it may result in another exception
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.
It would be nice to figure out the root cause of the issue. May be open a lower priority bug. Then we could understand what's the best workaround is. For example, if it's caused by a race then using a lock around Clear() could be a better solution.
One side effect of removing items one by one could be sending too many/often notifications to the subscribers, which can affect UX responsiveness or cause some issues within the subscribers if they didn't expect that.
<value>Stop</value> | ||
<comment>Text for the stop operation shown for the environment.</comment> | ||
<data name="Operations_Shutdown" xml:space="preserve"> | ||
<value>Shutdown</value> |
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.
Isn't "Stop" the value that the designers wanted?
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.
Actually they decided to change it #2665 to match hyper-v
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.
So don't you want to link and close the issue with this PR?
Summary of the pull request
After testing environments more for any random crashes or things that may have been missed before release I found the following:
devhome/tools/Environments/DevHome.Environments/ViewModels/ComputeSystemViewModel.cs
Line 168 in f88a26c
DataExtractor
to use themSave
operation in theDataExtractor
so I added it inSetupTargetReviewView
to only show the version when an operating system property from the environment existsVideo of me performing multiple operations with no crashes in environments page, also shows save button:
Showing.multiple.operations.being.initiated.without.crashing.mp4
Showing version not showing up when the environment does not have the operating system as a property:
Showing.version.not.showing.up.when.the.environment.does.not.have.the.operating.system.as.a.property.mp4
Showing me creating a Dev Box which shows up in the environments page and now does not show up in set up environments page:
Showing.me.creating.a.Dev.Box.which.shows.up.in.the.environments.page.and.now.does.not.show.up.in.set.up.environments.page.mp4
References and relevant issues
Detailed description of the pull request / Additional comments
Validation steps performed
PR checklist