2014-11-02 43 views
1

我使用陰謀沙箱和編譯WREQ庫時,我得到這個錯誤:WREQ不是陰謀沙編譯

Network/Wreq/Lens/Machinery.hs:20:58: 
    Couldn't match type `[Name]' with `Name' 
    Expected type: Name -> [Name] -> Name -> [DefName] 
     Actual type: [Name] -> Name -> [DefName] 
    In the return type of a call of `fieldName' 
    Probable cause: `fieldName' is applied to too many arguments 
    In the second argument of `(.~)', namely `fieldName id' 
    In the second argument of `(&)', namely `lensField .~ fieldName id' 
Failed to install wreq-0.2.0.0 

我使用這些庫在我的陰謀文件:

base >=4.6 && <4.7, 
    bytestring >=0.10 && <0.11, 
    aeson >=0.7 && <0.8, 
    yaml-config >= 0.2.0 && < 0.3, 
    HTTP >= 4000.0.7 &&< 4001, 
    base64-string >= 0.2 && < 0.3, 
    wreq >= 0.2.0.0 && < 0.3 

任何想法如何解決編譯錯誤?

回答

2

看起來像lens-4.5是罪魁禍首。

添加lens >= 4.4 && < 4.5到您的陰謀文件,它可能會編譯(它爲我做的。)

+0

謝謝。什麼導致了錯誤? – z1naOK9nu8iY5A 2014-11-03 08:03:12

+0

不知道 - 但最近打開了一個錯誤票:https://github.com/bos/wreq/issues/33 – ErikR 2014-11-03 15:56:04