title: Can't find OwinContext in NancyContext
body: <p>I have a self hosted Owin application that uses Nancy. In one of the NancyModules I need to get an instance of <code>IOwinContext</code>.</p>
  
  <p>This question touches on the subject, but there's no solution in it: <a href="https://stackoverflow.com/questions/26201032/get-current-owin-context-in-self-host-mode">Get current owin context in self host mode</a></p>
  
  <p>It says that for Nancy, you have to use NancyContext to get to the Items dictionary and look for the value corresponding to the key "OWIN_REQUEST_ENVIRONMENT".</p>
  
  <p>I do have access to the NancyContext and I can see the Items dictionary and that it contains a key called "OWIN_REQUEST_ENVIRONMENT". (I could also call the <code>NancyContext.GetOwinEnvironment()</code> extension, which gives the same result
  However, when I get that key it doesn't contain an actual IOwinContext.</p>
  
  <p>It contains a lot of keys with information about Owin (some of the keys are <em>owin.RequestPath</em>, <em>owin.RequestMethod</em>, <em>owin.CallCancelled</em>, and more), but not an actual context object. And it is only really a dictionary with various keys, so I can't cast it to an IOwinContext either.</p>
  
  <p>How can I get from a NancyContext to an IOwinContext object?</p>
  
  <hr>
  
  <pre><code>public class MyStartup
  {
      public void Start()
      {
          var options = new StartOptions()
          options.Urls.Add(new Uri("http://*:8084"));
          options.AppStartup(this.GetType().AssemblyQualifiedName;
          var host = WebApp.Start(options, Configuration);
      }
  
      public void Configuration(IAppBuilder app)
      {
          app.UseNancy();
      }
  }
  
  public class MyModule : NancyModule
  {
      Get["/", true] = async(x, ct) =&gt;
      {
          var owinEnvironment = Context.GetOwinEnvironment();
          // Now what?
      }
  }
  </code></pre>