Skip to content

System.InvalidOperationException Stack empty when using SM.MVC5  #14

@martsinkevich

Description

@martsinkevich

Hello,
After installing SM.MVC5 package got next exception System.InvalidOperationException Stack empty. in case when you try to display circular object dependency with partial view.

Ex.
@model WebApplication.Models.Test

@foreach (var val in Model.Tests) { @Html.Partial(val.GetType().Name, val) }

or just @Html.DisplayFor(model=>model.Tests)

Object example:
public class Test
{
public ICollection Tests { get; set; }
}

Any thoughts how it is possible to resolve?
Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions