XAML hot reloading: Stop crashing Smugleaf's game (and Sloth's)#5406
Draft
nyeogmi wants to merge 1 commit into
Draft
XAML hot reloading: Stop crashing Smugleaf's game (and Sloth's)#5406nyeogmi wants to merge 1 commit into
nyeogmi wants to merge 1 commit into
Conversation
The assembly being generated by the JIT compiler doesn't have actual access to widgets inside Robust.Client. It probably should. There's a companion change to our fork of XamlX that gives XamlX access to types internal to Robust.Client. Note that this change is only needed if you've hacked XamlX to be able to see types inside of Robust.Client.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
(This draft exists in two files. The XamlX part is here.)
The hot reloading code has these four underlying problems:
Two people have complained about these problems:
I think we have a few non-mutually exclusive options to address this:
If we do any of options 2, 3 and 4, we can log to WARN instead of INFO, as no failures are expected.
Note that failures will still occur in cases where people type broken code into their editor and save it -- I cannot guarantee that anybody's code will compile when the hot reloader sees it, and will continue to do my best to not take down the process when it happens.
This draft is an implementation of option 4. (Options 2 and 3 are trivial.) I personally think option 1 is the most reasonable -- ultimately I have no control of how XamlX signals errors -- but I leave the decision of what to do in the hands of the maintainers.