After upgrading from Sitecore 8.1 to 8.2, we continue to see the following error when working in CM. Users can login and begin working in Sitecore, but after a random amount of time, they get the the error. The only way to clear the error is to close the browser.
The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>).
Server Error in '/' Application.
The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>).
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Web.HttpException: The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>).
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace: [HttpException (0x80004005): The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>).] System.Web.UI.ControlCollection.Add(Control child) +11843103 Sitecore.MediaFramework.Pipelines.RenderLayout.RenderLayoutBase.Render(RenderLayoutArgs args) +256 Sitecore.MediaFramework.Pipelines.RenderLayout.RenderLayoutBase.Process(RenderLayoutArgs args) +108 (Object , Object[] ) +174 Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args) +479 Sitecore.Pipelines.DefaultCorePipelineManager.Run(String pipelineName, PipelineArgs args, String pipelineDomain) +22 Sitecore.Layouts.PageContext.BuildControlTree(Object sender, EventArgs e) +214 System.Web.UI.Page.OnPreInit(EventArgs e) +11869081 System.Web.UI.Page.PerformPreInit() +46 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1120
Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.7.2106.0
http://domain/sitecore/login?someQuery=string
?