O.P. - 2013-12-04

Hi,

After some time, DAVMail IMAP stops working : new emails are not downloaded anymore in iOS7 Mail configured with IMAP. Disabling the iOS IMAP account and re-enabling it solves the issue but it's very painful and long (full resync...).

The DAVMail log show some errors (related to the issue ?) :

Date:           Wed Dec 04 14:36:27 CET 2013 (1386164187492)
Thread:     ImapConnection-4428
Message #:  4994
Level:      ERROR
NDC:            
Category:   davmail
Message:        ErrorContainsFilterWrongType The Contains filter can only be used for string properties.
 request: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages"><soap:Header><t:RequestServerVersion Version="Exchange2010_SP1"/></soap:Header><soap:Body><m:FindItem Traversal="Shallow"><m:ItemShape><t:BaseShape>IdOnly</t:BaseShape><t:AdditionalProperties><t:ExtendedFieldURI DistinguishedPropertySetId="Common" PropertyId="34160" PropertyType="Integer"/><t:ExtendedFieldURI PropertyTag="0x670e" PropertyType="String"/><t:ExtendedFieldURI DistinguishedPropertySetId="InternetHeaders" PropertyName="content-class" PropertyType="String"/><t:ExtendedFieldURI PropertyTag="0xe08" PropertyType="Integer"/><t:FieldURI FieldURI="message:IsRead"/><t:ExtendedFieldURI PropertyTag="0x1081" PropertyType="Integer"/><t:ExtendedFieldURI PropertyTag="0xe07" PropertyType="Integer"/><t:ExtendedFieldURI DistinguishedPropertySetId="PublicStrings" PropertyName="Keywords" PropertyType="StringArray"/><t:ExtendedFieldURI PropertyTag="0xe23" PropertyType="Integer"/><t:ExtendedFieldURI PropertyTag="0x10f3" PropertyType="String"/><t:ExtendedFieldURI PropertyTag="0xe06" PropertyType="SystemTime"/><t:ExtendedFieldURI PropertyTag="0xff9" PropertyType="Binary"/><t:ExtendedFieldURI PropertyTag="0x1090" PropertyType="Integer"/><t:ExtendedFieldURI PropertyTag="0x3008" PropertyType="SystemTime"/><t:ExtendedFieldURI PropertyTag="0x1083" PropertyType="Integer"/></t:AdditionalProperties></m:ItemShape><m:IndexedPageItemView MaxEntriesReturned="100" Offset="0" BasePoint="Beginning"/><m:Restriction><t:Contains ContainmentMode="Substring" ContainmentComparison="IgnoreCase"><t:ExtendedFieldURI DistinguishedPropertySetId="PublicStrings" PropertyName="Keywords" PropertyType="StringArray"/><t:Constant Value="$Forwarded"/></t:Contains></m:Restriction><m:SortOrder><t:FieldOrder Order="Descending"><t:ExtendedFieldURI PropertyTag="0xe23" PropertyType="Integer"/></t:FieldOrder></m:SortOrder><m:ParentFolderIds><t:DistinguishedFolderId Id="inbox"/></m:ParentFolderIds></m:FindItem></soap:Body></soap:Envelope>
Location:   davmail.ui.tray.DavGatewayTray.displayMessage(DavGatewayTray.java:113)
Thrown:
davmail.exchange.ews.EWSException: ErrorContainsFilterWrongType The Contains filter can only be used for string properties.
 request: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages"><soap:Header><t:RequestServerVersion Version="Exchange2010_SP1"/></soap:Header><soap:Body><m:FindItem Traversal="Shallow"><m:ItemShape><t:BaseShape>IdOnly</t:BaseShape><t:AdditionalProperties><t:ExtendedFieldURI DistinguishedPropertySetId="Common" PropertyId="34160" PropertyType="Integer"/><t:ExtendedFieldURI PropertyTag="0x670e" PropertyType="String"/><t:ExtendedFieldURI DistinguishedPropertySetId="InternetHeaders" PropertyName="content-class" PropertyType="String"/><t:ExtendedFieldURI PropertyTag="0xe08" PropertyType="Integer"/><t:FieldURI FieldURI="message:IsRead"/><t:ExtendedFieldURI PropertyTag="0x1081" PropertyType="Integer"/><t:ExtendedFieldURI PropertyTag="0xe07" PropertyType="Integer"/><t:ExtendedFieldURI DistinguishedPropertySetId="PublicStrings" PropertyName="Keywords" PropertyType="StringArray"/><t:ExtendedFieldURI PropertyTag="0xe23" PropertyType="Integer"/><t:ExtendedFieldURI PropertyTag="0x10f3" PropertyType="String"/><t:ExtendedFieldURI PropertyTag="0xe06" PropertyType="SystemTime"/><t:ExtendedFieldURI PropertyTag="0xff9" PropertyType="Binary"/><t:ExtendedFieldURI PropertyTag="0x1090" PropertyType="Integer"/><t:ExtendedFieldURI PropertyTag="0x3008" PropertyType="SystemTime"/><t:ExtendedFieldURI PropertyTag="0x1083" PropertyType="Integer"/></t:AdditionalProperties></m:ItemShape><m:IndexedPageItemView MaxEntriesReturned="100" Offset="0" BasePoint="Beginning"/><m:Restriction><t:Contains ContainmentMode="Substring" ContainmentComparison="IgnoreCase"><t:ExtendedFieldURI DistinguishedPropertySetId="PublicStrings" PropertyName="Keywords" PropertyType="StringArray"/><t:Constant Value="$Forwarded"/></t:Contains></m:Restriction><m:SortOrder><t:FieldOrder Order="Descending"><t:ExtendedFieldURI PropertyTag="0xe23" PropertyType="Integer"/></t:FieldOrder></m:SortOrder><m:ParentFolderIds><t:DistinguishedFolderId Id="inbox"/></m:ParentFolderIds></m:FindItem></soap:Body></soap:Envelope>
    at davmail.exchange.ews.EWSMethod.checkSuccess(EWSMethod.java:713)
    at davmail.exchange.ews.EwsExchangeSession.executeMethod(EwsExchangeSession.java:2227)
    at davmail.exchange.ews.EwsExchangeSession.searchItems(EwsExchangeSession.java:697)
    at davmail.exchange.ews.EwsExchangeSession.searchMessages(EwsExchangeSession.java:667)
    at davmail.exchange.ExchangeSession.searchMessages(ExchangeSession.java:829)
    at davmail.exchange.ExchangeSession$Folder.searchMessages(ExchangeSession.java:1649)
    at davmail.imap.ImapConnection.handleSearch(ImapConnection.java:1012)
    at davmail.imap.ImapConnection.run(ImapConnection.java:330)

and :

Date:           Wed Dec 04 14:56:33 CET 2013 (1386165393868)
Thread:     ImapConnection-48076
Message #:  20521
Level:      DEBUG
NDC:            
Category:   davmail
Message:        > 10 BAD unable to handle request: ErrorContainsFilterWrongType The Contains filter can only be used for string properties.  request: <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:m="http://schemas.microsoft.com/exchange/services/2006/messages"><soap:Header><t:RequestServerVersion Version="Exchange2010_SP1"/></soap:Header><soap:Body><m:FindItem Traversal="Shallow"><m:ItemShape><t:BaseShape>IdOnly</t:BaseShape><t:AdditionalProperties><t:ExtendedFieldURI DistinguishedPropertySetId="Common" PropertyId="34160" PropertyType="Integer"/><t:ExtendedFieldURI PropertyTag="0x670e" PropertyType="String"/><t:ExtendedFieldURI DistinguishedPropertySetId="InternetHeaders" PropertyName="content-class" PropertyType="String"/><t:ExtendedFieldURI PropertyTag="0xe08" PropertyType="Integer"/><t:FieldURI FieldURI="message:IsRead"/><t:ExtendedFieldURI PropertyTag="0x1081" PropertyType="Integer"/><t:ExtendedFieldURI PropertyTag="0xe07" PropertyType="Integer"/><t:ExtendedFieldURI DistinguishedPropertySetId="PublicStrings" PropertyName="Keywords" PropertyType="StringArray"/><t:ExtendedFieldURI PropertyTag="0xe23" PropertyType="Integer"/><t:ExtendedFieldURI PropertyTag="0x10f3" PropertyType="String"/><t:ExtendedFieldURI PropertyTag="0xe06" PropertyType="SystemTime"/><t:ExtendedFieldURI PropertyTag="0xff9" PropertyType="Binary"/><t:ExtendedFieldURI PropertyTag="0x1090" PropertyType="Integer"/><t:ExtendedFieldURI PropertyTag="0x3008" PropertyType="SystemTime"/><t:ExtendedFieldURI PropertyTag="0x1083" PropertyType="Integer"/></t:AdditionalProperties></m:ItemShape><m:IndexedPageItemView MaxEntriesReturned="100" Offset="0" BasePoint="Beginning"/><m:Restriction><t:Contains ContainmentMode="Substring" ContainmentComparison="IgnoreCase"><t:ExtendedFieldURI DistinguishedPropertySetId="PublicStrings" PropertyName="Keywords" PropertyType="StringArray"/><t:Constant Value="$Forwarded"/></t:Contains></m:Restriction><m:SortOrder><t:FieldOrder Order="Descending"><t:ExtendedFieldURI PropertyTag="0xe23" PropertyType="Integer"/></t:FieldOrder></m:SortOrder><m:ParentFolderIds><t:DistinguishedFolderId Id="inbox"/></m:ParentFolderIds></m:FindItem></soap:Body></soap:Envelope>
Location:   davmail.ui.tray.DavGatewayTray.displayMessage(DavGatewayTray.java:96)
Thrown:

Any idea ?