Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Khai 71 posts 161 karma points
    Jul 16, 2013 @ 17:19
    Khai
    0

    Teacommerce stopped working: Context is null

    So I was working on my website, when suddenly I noticed TeaCommerce stopped working:

    System.ArgumentNullException: Value cannot be null.

    Parameter name: context

       at Autofac.ResolutionExtensions.ResolveService(IComponentContext context, Service service, IEnumerable`1 parameters)

       at Autofac.ResolutionExtensions.Resolve[TService](IComponentContext context, IEnumerable`1 parameters)

       at TeaCommerce.Umbraco.Application.Trees.StoreTree.CreateRootNode(XmlTreeNode& rootNode)

       at umbraco.presentation.webservices.TreeDataService.LoadAppTrees(TreeRequestParams treeParams)

       at umbraco.presentation.webservices.TreeDataService.ProcessRequest(HttpContext context)

       at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()

       at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

    2013-07-16 16:55:07,403 [36] INFO  Umbraco.Core.PluginManager - [Thread 8] Starting resolution types of Umbraco.Core.Persistence.Mappers.BaseMapper

    2013-07-16 16:55:07,427 [36] INFO  Umbraco.Core.PluginManager - [Thread 8] Completed resolution of types of Umbraco.Core.Persistence.Mappers.BaseMapper, found 17 (took 24ms)

    Somehow the context for Autofac is null.. 

  • Merijn van Mourik 58 posts 128 karma points
    Jul 16, 2013 @ 20:23
    Merijn van Mourik
    0

    Hi,

    Could it be the TeaCommerce store picker property is missing from the Content Tree?

    Merijn

  • Khai 71 posts 161 karma points
    Jul 16, 2013 @ 20:48
    Khai
    0

    Hi,

    Well I first noticed the error was when I added a property to the root node ( which also has the store picker property ). I tried to edit the root node, and it gave me the error. So when I went to the tea commerce section, I got the same error.. 

    I tried to uninstall/install tea commerce and I still have the same problem. So what I just did was I got the source code of yesterday and then it suddenly does work.. I didn't add that much code today.. except some functionality for bundling by adding System.web.optimization. I'm still not quite sure if this is the cause though.

     

  • Khai 71 posts 161 karma points
    Jul 16, 2013 @ 20:56
    Khai
    0

    Ok, so I removed my code and the dlls for System.Web.Optimization and now it's running fine again. Can someone from TeaCommerce clarify this behaviour? I'd really like to use bundling though.

  • Merijn van Mourik 58 posts 128 karma points
    Jul 16, 2013 @ 21:28
    Merijn van Mourik
    0

    Interesting. I 'm using Optimus for bundling/minification, it runs fine with TeaCommerce. But the root node thing. Could be something went wrong when publishing. Do you have a copy of the logs? Might be the error is in there.

  • Rune Grønkjær 1371 posts 3102 karma points
    Jul 17, 2013 @ 09:44
    Rune Grønkjær
    0

    Hi Khai,

    I cannot give you an answer right away as I'm not the one that built the Tea Commerce core. Anders, who did build it, is traveling the US at the moment. I will have him answer as soon as posible!

    /Rune

  • Khai 71 posts 161 karma points
    Jul 17, 2013 @ 10:09
    Khai
    0

    @Merijn thanks for the suggestion for using Optimus, I'll try it out! @Rune thank, I'd gladly like to know :)

  • Khai 71 posts 161 karma points
    Jul 17, 2013 @ 10:42
    Khai
    0

    Installing optimus also breaks teacommerce, same error.. probably because of the same dlls ( System.web.optimization ) and WebGrease.dll

  • Anders Burla 2560 posts 8256 karma points
    Jul 21, 2013 @ 06:52
    Anders Burla
    0

    Hi Khai

    @Merijn - could you try and help - because if Optimus works for you - it should work for @Khai as well :)

    If something goes wrong with some custom Autofac code then everything of the registration of Autofac code in TC will go wrong and it wont work. So try and look at the AppData/Logs files and see what the exception says - the stracktrace should give you a hint.

    Kind regards
    Anders 

  • Peter Duncanson 430 posts 1360 karma points c-trib
    Oct 20, 2014 @ 16:37
    Peter Duncanson
    0

    We had this on version Tea Commerce 2.2 but after talking through with Anders we updated to version 2.5 and the issues went away. He said it should be long gone after 2.4+

    Careful when upgrading though, there are some breaking changes, check the release docs.

    Hope that helps someone.

Please Sign in or register to post replies

Write your reply to:

Draft