0

During Sitecore upgrade from 9.0 to 10.2, I am getting the following error -

Server Error in '/' Application.
Method not found: 'System.Web.HttpContext Sitecore.Pipelines.HttpRequest.HttpRequestArgs.get_Context()'.
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.MissingMethodException: Method not found: 'System.Web.HttpContext Sitecore.Pipelines.HttpRequest.HttpRequestArgs.get_Context()'.

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:


[MissingMethodException: Method not found: 'System.Web.HttpContext Sitecore.Pipelines.HttpRequest.HttpRequestArgs.get_Context()'.]
   Unicorn.ControlPanel.UnicornControlPanelPipelineProcessor.Process(HttpRequestArgs args) +0
   (Object , Object ) +14
   Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args) +1268
   Sitecore.Pipelines.DefaultCorePipelineManager.Run(String pipelineName, PipelineArgs args, String pipelineDomain, Boolean failIfNotExists) +236
   Sitecore.Pipelines.DefaultCorePipelineManager.Run(String pipelineName, PipelineArgs args, String pipelineDomain) +22
   Sitecore.Web.RequestEventsHandler.OnPostAuthenticateRequest(HttpContextBase context) +218
   System.Web.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +223
   System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step) +220
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +94

I tried removing unicorn files and configs as suggested by some forums. but that leads to a "Layout not found error"

Any suggestions on what steps need to be taken? What version should I use for Unicorn?

Any help would be appreciated.

1 Answer 1

0

By looking at the error it seems that you have an older version of Unicorn in your repository because it is trying to access a method that is not available in later versions, now to fix this you need to remove the older version of Unicorn from your instance.

Now if you see this article, the author is using version 4.1.5, which is compatible with Sitecore 10. Read this article for more details.

https://www.sam-solutions.com/blog/set-up-sitecore-unicorn/

And if you see the latest version in the below article, it is 4.1.7-pre1. So I think you need to try this one. See the nuget version here.

https://www.nuget.org/packages/Unicorn/

Finally, if you will see the Unicorn readme file, it will show some changes in configs that are compatible with Sitecore 10.1 and above. Read this.

https://github.com/SitecoreUnicorn/Unicorn/blob/master/Build/Unicorn.nuget/readme.txt

So you should try the latest release and it will solve your issue.

And one more thing is if you still get some issue after installation then you can join the Sitecore Community Slack and ask in #unicorn. You will get more help from the authors on this.

Hope this helps.

6
  • I updated the Unicorn to version 4.1.6, After that I am getting following error - Method 'Save' in type 'Unicorn.Data.ConfigurationDataStore' from assembly 'Unicorn, Version=4.1.6.0, Culture=neutral, PublicKeyToken=null' does not have an implementation. configs looks fine. Don't understand what is wrong
    – SummiJ
    Jan 5 at 8:35
  • Yes I did check. But that post is suggesting unicorn version upgrade itself.
    – SummiJ
    Jan 5 at 19:33
  • I am checking if some changes need to be done in config level. no luck so far.
    – SummiJ
    Jan 5 at 19:35
  • As per the comments given by the author, I think you probably have some leftover assemblies in your obj folder. Run a full "Clean Solution" and republish the solution. Also make sure you're using the 4.1.0+ version of Unicorn.config. Also; the 4.1.0 release needs Rainbow 2.1.0. Refer to this link github.com/SitecoreUnicorn/Unicorn/issues/351 Jan 6 at 8:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.