Various exceptions after 4.0 -> 4.1 upgrade - Bugs & Issues - Bugs & Issues - Progress Community

Various exceptions after 4.0 -> 4.1 upgrade

 Bugs & Issues

Various exceptions after 4.0 -> 4.1 upgrade

  • Various exceptions after 4.0 -> 4.1 upgrade
  • Hi, all.
    I ran into problems right after upgrade.
    Configuration error has occured (see sf_error1.png attachment).
    I've foudnd all "4.0.1098.0" version occurences for "Telerik.Sitefinity.Utilities" library references in web.config and replaced to "4.1.1339.0" ("Telerik.Sitefinity.Utilities.dll" library version is "4.1.1339.0" at this moment).
    "Could not load file or assembly" exception has occured (see sf_error2.png attachment).
    Than I've built my project once again and restarted w3wp application.
    So, new exception has occured (see sf_error3.png attachment).
    And I don't know what to do... Help me, please.

  • In addition, last exception always occuring when I see the page in public mode ( localhost/membership-renewals )
    But there is no exceptions in edit mode and in preview mode ( localhost/.../Preview ).
    So, I feel free to create new pages... but I can't show them to others.
  • 265911_sf-title.png
    So, there is another problem. I cannot create a page if HTML title contains comma or ampersand etc...
    See attachment.
    How can I allow to use punctuation marks in title?
  • Hello Anatoliy,

    The first errors say that there is some problem loading dlls - the solution does not have proper reference to the correct dlls or they are not in your bin folder. In the another screenshot I see that there is reference to 1098 which is the official release, so make sure that you set the proper reference and if you have custom controls they do not refer the old dlls

    You can alter the page filed validation from Administration >> Settings >>ContentView >> Controls >>
    BackendPages >> Views >> BackendPagesCreate >> Toolbar >> Sections

    Regards,
    Ivan Dimitrov
    the Telerik team

  • Hello Ivan,

    Thanks, I've found and updated needed options in Settings and title problem is resolved.

    But I still have a problem with exception ( sf-error3.png )
    1) I've checked all Telerik.Sitefinity.* dll's from bin folder. All these dll's versions are 4.1.1339.0.
    2) I've checked all solutions for 4.0.1098.0. Found some occurences in ToolboxesConfig.config file and replaced to 4.1.1339.0.
    3) I've checked all database objects for 4.0.1098.0. Found some occurences in sf_data_objects table and replacet to 4.1.1339.0.

    Exception ( sf-error3.png ) is still being thrown but I've got to isolate the sore! So, If one of my custom layouts is used on the page - the exception will be thrown invariably!
    I cannot understand how my custom layouts are take effect. Please, help me!

    Here is some information.

    1)Custom layout source code:

    namespace SitefinityWebApp.Layouts.PageLayouts.TwoColumns
        public class LayoutControl : CustomLayoutControl
        
            protected override string LayoutTemplate
            
                get
                
                    return "SitefinityWebApp.Layouts.PageLayouts.TwoColumns.Layout.LayoutTemplate.ascx";
                
            
        

    using Telerik.Sitefinity.Web.UI;
     
    namespace SitefinityWebApp.Layouts
        public abstract class CustomLayoutControl : LayoutControl
        
            protected abstract string LayoutTemplate get;
     
            public override sealed string Layout
            
                get
                
                    return LayoutTemplate;
                
            
     
            public override sealed string AssemblyInfo
            
                get
                
                    return GetType().ToString();
                
                set
                
                    base.AssemblyInfo = value;
                
            
        

    2) ASCX Layout template:

    <%@ Control Language="C#" %>
     
    <div runat="server" class="sf_cols bodyInner">
        <div runat="server" class="sf_colsOut bodyColumn bodyLeftColumn bodyContent">
            <div runat="server" class="sf_colsIn bodyColumnInner"></div>
        </div>
        <div runat="server" class="sf_colsOut bodyColumn bodyRightColumn black-green">
            <div runat="server" class="sf_colsIn bodyColumnInner"></div>
        </div>
    </div>

    3) Occurences in .csproj file:

    <Compile Include="Layouts\PageLayouts\TwoColumns\LayoutControl.cs" />
     
    <EmbeddedResource Include="Layouts\PageLayouts\TwoColumns\Layout\LayoutTemplate.ascx" />

    4) Layout usage from sf_object_data table:

    Columns: 'app_name', 'collection_index', 'dictionary_key', 'id', 'last_modified', 'object_type', 'parent_prop_id', 'voa_class', 'voa_version', '<_editable>k___backing_field', 'allow_security', 'can_inherit_permissions', 'culture', 'id2', 'inherits_permissions', 'is_data_source', 'is_layout_control', 'ownr', 'place_holder', 'shred', 'sibling_id', 'content_id', 'published', 'id3', 'published2', 'page_id', 'description_', 'caption_', 'original_control_id'
     
    Values: 'WildApricot/', '0', 'NULL', 'B132A9D8-A4A1-42E5-B7DC-CCBBA68F14DD', '2011-04-27 13:23:43.680', 'SitefinityWebApp.Layouts.PageLayouts.TwoColumns.LayoutControl', 'NULL', '811529188', '2', 'NULL', '0', '0', 'NULL', 'NULL', '0', '0', '1', 'C35AFCAD-8449-4E13-A6EF-62DDB0059C81', 'MainPlaceHolder', '1', 'F7F76018-472C-44B4-8988-0881273FE2D1', 'NULL', 'NULL', 'NULL', 'NULL', 'NULL', 'NULL', 'TwoColumns', '71270A7B-584F-4446-A1A5-7082D07C84A6'

    5) Exception when see page in public mode:

    ---------------------------------

    Server Error in '/' Application.

    String reference not set to an instance of a String.
    Parameter name: s

    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.ArgumentNullException: String reference not set to an instance of a String.
    Parameter name: s

    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:

    [ArgumentNullException: String reference not set to an instance of a String.
    Parameter name: s]
       System.Text.Encoding.GetBytes(String s) +9393893
       Telerik.Sitefinity.Utilities.HtmlParsing.HtmlParser.Init(String html) +25
       Telerik.Sitefinity.Utilities.HtmlParsing.HtmlParser..ctor(String html) +190
       Telerik.Sitefinity.Abstractions.VirtualPath.SitefinityPageResolver.ProcessLayoutString(String template, PlaceHolderCursor parentPlaceHolder, CursorCollection placeholders, String layoutId) +55
       Telerik.Sitefinity.Abstractions.VirtualPath.SitefinityPageResolver.AppendLayout(String layoutTemplate, String assemblyInfo, PlaceHolderCursor parentPlaceHolder, CursorCollection placeHolders, String layoutId) +349
       Telerik.Sitefinity.Abstractions.VirtualPath.SitefinityPageResolver.BuildControls(PageData pageData, List`1 controlConatiners, CursorCollection placeHolders) +975
       Telerik.Sitefinity.Abstractions.VirtualPath.SitefinityPageResolver.RenderPage(StringBuilder output, PageData pageData, RequestContext context, String virtualPath) +186
       Telerik.Sitefinity.Abstractions.VirtualPath.SitefinityPageResolver.Open(PathDefinition definition, String virtualPath) +215
       Telerik.Sitefinity.Abstractions.VirtualPath.PathDefinition.OpenFile(String virtualPath) +32
       Telerik.Sitefinity.Abstractions.VirtualPath.VirtualPathManager.OpenFile(String virtualPath) +42
       Telerik.Sitefinity.Abstractions.VirtualPath.SitefinityVirtualFile.Open() +22
       System.Web.Hosting.VirtualPathProvider.OpenFile(String virtualPath) +31
       System.Web.UI.TemplateParser.ParseFile(String physicalPath, VirtualPath virtualPath) +133
       System.Web.UI.TemplateParser.ParseInternal() +86
       System.Web.UI.TemplateParser.Parse() +160
       System.Web.Compilation.BaseTemplateBuildProvider.get_CodeCompilerType() +110
       System.Web.Compilation.BuildProvider.GetCompilerTypeFromBuildProvider(BuildProvider buildProvider) +65
       System.Web.Compilation.BuildProvidersCompiler.ProcessBuildProviders() +218
       System.Web.Compilation.BuildProvidersCompiler.PerformBuild() +40
       System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath) +8945798
       System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) +320
       System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) +111
       System.Web.Compilation.BuildManager.GetVirtualPathObjectFactory(VirtualPath virtualPath, HttpContext context, Boolean allowCrossApp, Boolean throwIfNotFound) +125
       System.Web.Compilation.BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp) +52
       Telerik.Sitefinity.Web.PageRouteHandler.GetHttpHandler(RequestContext requestContext) +621
       System.Web.Routing.UrlRoutingModule.PostResolveRequestCache(HttpContextBase context) +8890312
       System.Web.Routing.UrlRoutingModule.OnApplicationPostResolveRequestCache(Object sender, EventArgs e) +86
       System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +148
       System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +75
    


    Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.1

    ---------------------------------

    6) There are no exceptions in Edit and Preview mode (even If i use any custom layouts in page).

    7) There are no logs in App_Data\Sitefinity\Logs\ folder (I've deleted old ones yesterday and ran into exception today many times - and there are no new logs yet).

    Thanks a lot for any assistance!
  • 267963_sf-error4.png
    I'm seriously worried about state of affairs.
    It's impossible to use Sitefinity because now there is no one usable page which contain at least one custom layout.
    And it's impossible to create new custom layouts after 4.0 -> 4.1 upgrade because all of them cannot dropped on page in edit Mode - see sf_error4.png attachment.
    And I really don't have the opportunity to revert 4.0 version: there were a serious bug with dropped SQL connection which was fixed in 4.1 ( www.sitefinity.com/.../database-connection-closed.aspx ). This bug is endurable for my local server but absolutely inadmissible for live publication.
  • Has there been any progress on this issue? The Telerik support teams seems to have grown quiet. I am having the same issue, I put in a ticket to the support team a few days ago:

    www.telerik.com/.../view-ticket.aspx

    And I have not had a response in over 24 hours since my last post. Is this a bug? It would be nice to know that using custom Layout Controls is a bug in 4.1. This is frustrating and infuriating. No one seems to know anything about how to solve this. My custom Layout Control was working in 4.0 before the upgrade and now it isn't. I can only see it in Edit mode and Preview mode, but on the live page I keep getting an "Invalid Layout Template" exception. What is going on?

    Any response at this point from the Telerik team would be greatly appreciated. Leaving us in the dark is not good practice!
  • Hi Leng,

    Please take a look at this forum post where I attached a working sample and video that shows how the control works properly without throwing an exception.

    http://www.sitefinity.com/devnet/forums/sitefinity-4-x/bugs-issues/layoutcontrol-templates-need-the-provider-fix.aspx

    I hope this helps.

    All the best,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items