haskell - type mismatch on Network.Wai.Middleware -
I am trying to follow static files with Scotty to serve. So I have a small script:
Import the # - language overloaded strings # -} Web. Scotty Import Network why. Mildware. Physical Import Data. Monoide (Mconcrack) main = $ 3,000 Taxes Middleweight $ static policy (no dots & gt; - adbase "stable") "/: The word" $ beam " - The ultimate "word" html $ mconcat ["& lt; h1 & gt; Scotty,", beam, "me up! " / h1> "] The ghc generates the following error:
server.hs: 9: 16 type 'network could not be matched with Y. Inherent. With 'Y-1.0.0.1': Networks why. Request 'Required Type: Y-1.4.0.1: Networks why. Mildware real type: network. why. In Mildlveyr second argument of `static policy in exchange for a call 'Men` ($)', namely` static; policy (No dots & gt - & gt; Adbs "stable") a 'Dblutim' block: middleware $ Static policy (no dots & gt; - & gt code I no longer understand that wai-1.4.0.1: network .Y.Mildware < / Code> vs network Wai.Middleware . Is this a version issue? I tried to check the installed library, but I No conflicts have been found. What should I check to resolve this?
Edit ghc- pkg list wai running C: \ perso \ prog \ haskell \ orgmode \ orgmodeserver \ src \ hs gt gt- gtc- pkg list Y Warning: broken package run. for more information 'ghc-pkg Czech. C: / program files (x86) / Haskell platform / 2013.2.0.0 \ lib \ package.conf.d: C: \ users \ sberg \ AppData \ roaming \ ghc \ I386-mingw32-7.6.3 \ package.conf.d: Wai-1.4.0.1 wai-2.0.0 is running ghc-pkg check ( F Leave a bunch of Tavnion): is broken following packages, either because they have problems listed above, or because they depend on a broken package. Skion browser -0.2.17 Miam time -0.0.0 Test Yes -0.0.0 Hood-platform -1.2.2 sea -1.2.1.1 Hnod-Eighth -1.2.0.2 sea-form -1.3.0.1 < Perhaps there are a dozen different ways to fix this, but the easiest solution is to remove all broken packages. To cancel, both versions of unregistered Y and reinstall all packages, make sure that you are not installing 2 versions of Y. Use the flag - drawer-run to make sure that the cables installed are not installing the older version. If it decides that it requires 1.4 and can not use 2.0, then you may have to use older versions of some packages.
Comments
Post a Comment