Skip to content

Conversation

@pranavkm
Copy link
Contributor

The server requires that clients send descriptors in sequence. Since MVC executes
Layouts in an inside-out manner, modify the client to explicitly order descriptors

Fixes #14474

The server requires that clients send descriptors in sequence. Since MVC executes
Layouts in an inside-out manner, modify the client to explicitly order descriptors

Fixes #14474
@pranavkm
Copy link
Contributor Author

No idea if this messes up a scenario, but all of the tests pass locally.

@pranavkm
Copy link
Contributor Author

Layouts in MVC are rendered inside out, consequently any components in a Layout page that appear before RenderBody will have an out of order sequence number:

// _Layout.cshtml
<component type="Counter" />: sequence: 1

@RenderBody()
    // Index.cshtml
    <component type="Counter" />: sequence: 0

// _Layout.cshtml
<component type="Counter" />: sequence: 2

This trips the deserialization when it sees out-of-order sequence numbers.

@pranavkm pranavkm added this to the 3.1.0-preview2 milestone Oct 14, 2019
Copy link
Member

@javiercn javiercn left a comment

Choose a reason for hiding this comment

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

This sounds like a great fix, it is how it was supposed to work, we just thought they were in order already.

I’m glad it wasn’t an issue with the viewcontext not being properly copied.

@pranavkm pranavkm merged commit 30b31d7 into release/3.1 Oct 15, 2019
@pranavkm pranavkm deleted the prkrishn/layout-components branch October 15, 2019 20:17
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.

3 participants