From owner-freebsd-ports-bugs@FreeBSD.ORG Tue Feb 12 18:20:02 2013 Return-Path: Delivered-To: freebsd-ports-bugs@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 113C64EB for ; Tue, 12 Feb 2013 18:20:02 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) by mx1.freebsd.org (Postfix) with ESMTP id EB22E8B9 for ; Tue, 12 Feb 2013 18:20:01 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.6/8.14.6) with ESMTP id r1CIK1AU037739 for ; Tue, 12 Feb 2013 18:20:01 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.6/8.14.6/Submit) id r1CIK12B037738; Tue, 12 Feb 2013 18:20:01 GMT (envelope-from gnats) Resent-Date: Tue, 12 Feb 2013 18:20:01 GMT Resent-Message-Id: <201302121820.r1CIK12B037738@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Matthew West Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 466A3355 for ; Tue, 12 Feb 2013 18:11:48 +0000 (UTC) (envelope-from mwest@zeeb.org) Received: from zeeb.org (unknown [IPv6:2a01:4f8:120:82c0::2]) by mx1.freebsd.org (Postfix) with ESMTP id 07A77856 for ; Tue, 12 Feb 2013 18:11:47 +0000 (UTC) Received: from mwest by zeeb.org with local (Exim 4.80.1 (FreeBSD)) (envelope-from ) id 1U5KKY-000PXh-UP for FreeBSD-gnats-submit@freebsd.org; Tue, 12 Feb 2013 20:11:46 +0200 Message-Id: Date: Tue, 12 Feb 2013 20:11:46 +0200 From: Matthew West Sender: Matthew West To: FreeBSD-gnats-submit@freebsd.org X-Send-Pr-Version: 3.113 Subject: ports/176079: [patch] mail/offlineimap: fix read-only folders X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: Matthew West List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Feb 2013 18:20:02 -0000 >Number: 176079 >Category: ports >Synopsis: [patch] mail/offlineimap: fix read-only folders >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Tue Feb 12 18:20:00 UTC 2013 >Closed-Date: >Last-Modified: >Originator: Matthew West >Release: FreeBSD 8.3-RELEASE-p3 amd64 >Organization: >Environment: >Description: Adds the patch from rea@ that fixes handling of read-only folders (e.g. GMail's Chat folder). Eygene, as you're also port maintainer, would you mind adding this patch to the port? I've been hoping for an updated version of offlineimap to be released, but it's been stuck at RC for almost 6 months now. Thanks, Matthew >How-To-Repeat: >Fix: --- offlineimap.diff begins here --- diff -ruN offlineimap.orig/Makefile offlineimap/Makefile --- offlineimap.orig/Makefile 2012-11-17 07:59:07.000000000 +0200 +++ offlineimap/Makefile 2013-02-12 20:00:43.235994144 +0200 @@ -7,6 +7,7 @@ PORTNAME= offlineimap DISTVERSION= 6.5.4 +PORTREVISION= 1 CATEGORIES= mail python MASTER_SITES= http://cloud.github.com/downloads/spaetz/offlineimap/ \ http://dist.codelabs.ru/fbsd/offlineimap/ diff -ruN offlineimap.orig/files/patch-properly-detect-readonly-folders offlineimap/files/patch-properly-detect-readonly-folders --- offlineimap.orig/files/patch-properly-detect-readonly-folders 1970-01-01 02:00:00.000000000 +0200 +++ offlineimap/files/patch-properly-detect-readonly-folders 2012-08-05 20:43:01.000000000 +0200 @@ -0,0 +1,32 @@ +From 9ad8f76a4313b83587fc44c8c864c52f02a4692c Mon Sep 17 00:00:00 2001 +From: Eygene Ryabinkin +Date: Sun, 5 Aug 2012 22:40:52 +0400 +Subject: [PATCH] IMAPlib mixin class: pass 'readonly' exception to our + callers + +This will allow our callers who are capable of dealing with +readonly folders to properly detect this condition and act +accordingly. + +Signed-off-by: Eygene Ryabinkin +--- + offlineimap/imaplibutil.py | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/offlineimap/imaplibutil.py b/offlineimap/imaplibutil.py +index aa165f0..4290b2b 100644 +--- a/offlineimap/imaplibutil.py ++++ b/offlineimap/imaplibutil.py +@@ -49,6 +49,9 @@ class UsefulIMAPMixIn(object): + del self.untagged_responses[:] + try: + result = super(UsefulIMAPMixIn, self).select(mailbox, readonly) ++ except self.readonly as e: ++ # pass self.readonly to our callers ++ raise + except self.abort as e: + # self.abort is raised when we are supposed to retry + errstr = "Server '%s' closed connection, error on SELECT '%s'. Ser"\ +-- +1.7.11.1 + --- offlineimap.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted: