View | Details | Raw Unified | Return to bug 262233 | Differences between
and this patch

Collapse All | Expand All

(-)b/mail/Makefile (+1 lines)
Lines 506-511 Link Here
506
    SUBDIR += py-milter
506
    SUBDIR += py-milter
507
    SUBDIR += py-notmuch
507
    SUBDIR += py-notmuch
508
    SUBDIR += py-notmuch2
508
    SUBDIR += py-notmuch2
509
    SUBDIR += py-offlineimap3
509
    SUBDIR += py-postfix-mta-sts-resolver
510
    SUBDIR += py-postfix-mta-sts-resolver
510
    SUBDIR += py-premailer
511
    SUBDIR += py-premailer
511
    SUBDIR += py-pymailq
512
    SUBDIR += py-pymailq
(-)b/mail/py-offlineimap3/Makefile (+89 lines)
Added Link Here
1
PORTNAME=	offlineimap3
2
PORTVERSION=	8.0.0
3
DISTVERSIONPREFIX=	v
4
CATEGORIES=	mail python
5
PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
6
7
MAINTAINER=	dereks@lifeofadishwasher.com
8
COMMENT=	Two-way synchronization of local Maildir and IMAP folders
9
10
LICENSE=	GPLv2
11
LICENSE_FILE=	${WRKSRC}/COPYING
12
13
# setup.py requires these during build time. Possible move to setup/install_requires:
14
# https://github.com/OfflineIMAP/offlineimap3/issues/110
15
BUILD_DEPENDS=	${PYTHON_PKGNAMEPREFIX}distro>=0:sysutils/py-distro@${PY_FLAVOR} \
16
		${PYTHON_PKGNAMEPREFIX}imaplib2>=3.5:mail/py-imaplib2@${PY_FLAVOR} \
17
		${PYTHON_PKGNAMEPREFIX}rfc6555>=0:mail/py-rfc6555@${PY_FLAVOR} \
18
		${PYTHON_PKGNAMEPREFIX}sqlite3>=0:databases/py-sqlite3@${PY_FLAVOR}
19
RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}certifi>=2020.6.20:security/py-certifi@${PY_FLAVOR} \
20
		${PYTHON_PKGNAMEPREFIX}distro>=0:sysutils/py-distro@${PY_FLAVOR} \
21
		${PYTHON_PKGNAMEPREFIX}imaplib2>=3.5:mail/py-imaplib2@${PY_FLAVOR} \
22
		${PYTHON_PKGNAMEPREFIX}rfc6555>=0:mail/py-rfc6555@${PY_FLAVOR} \
23
		${PYTHON_PKGNAMEPREFIX}sqlite3>=0:databases/py-sqlite3@${PY_FLAVOR} \
24
		${PYTHON_PKGNAMEPREFIX}urllib3>=1.25.9:net/py-urllib3@${PY_FLAVOR}
25
TEST_DEPENDS=	${PYTHON_PKGNAMEPREFIX}pytest>0:devel/py-pytest@${PY_FLAVOR}
26
27
# Upstream doesn't have exact version currently only able to test up to 3.9 since
28
# imaplib2 is 3.6-3.9.
29
USES=		python:3.7-3.9
30
31
# Project is currently not publishing to pypi sdist.  pypi/naming status:
32
# https://github.com/OfflineIMAP/offlineimap3/issues/111
33
USE_GITHUB=	yes
34
GH_ACCOUNT=	OfflineIMAP
35
36
USE_PYTHON=	autoplist concurrent distutils
37
38
CONFLICTS_INSTALL=	mail/py-offlineimap
39
40
NO_ARCH=	yes
41
42
PORTDOCS=	*
43
PORTEXAMPLES=	offlineimap.conf
44
45
OPTIONS_DEFINE=		DOCS EXAMPLES GSSAPI MANPAGES
46
OPTIONS_DEFAULT=	MANPAGES
47
48
COMMON_BUILD_DEPENDS=	a2x:textproc/asciidoc \
49
			gmake:devel/gmake
50
51
DOCS_BUILD_DEPENDS=	${COMMON_BUILD_DEPENDS} \
52
			${PYTHON_PKGNAMEPREFIX}sphinx>=0:textproc/py-sphinx@${PY_FLAVOR}
53
54
GSSAPI_RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}gssapi>=1.6.9:security/py-gssapi@${PY_FLAVOR}
55
56
MANPAGES_BUILD_DEPENDS=	${COMMON_BUILD_DEPENDS}
57
MANPAGES_PLIST_FILES+=	man/man1/offlineimap.1.gz \
58
			man/man7/offlineimapui.7.gz
59
60
# In concurrent env. sphinx-build is only exist for py38 add "-${PYTHON_VER}" to command
61
post-patch:
62
	cd ${WRKSRC} && \
63
	${REINPLACE_CMD} '/^SPHINXBUILD = sphinx-build$$/s/$$/-${PYTHON_VER}/' \
64
		docs/Makefile
65
66
post-build-DOCS-on:
67
	${MKDIR} ${STAGEDIR}${DOCSDIR}
68
	cd ${WRKSRC}/docs && ${GMAKE} docs && \
69
	cd html && \
70
	${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR} \
71
		'! ( -name .lock -or -name .buildinfo )'
72
73
post-build-MANPAGES-on:
74
	${MKDIR} ${STAGEDIR}${MAN7PREFIX}/man/man7/
75
	${MKDIR} ${STAGEDIR}${MAN7PREFIX}/man/man1/
76
	cd ${WRKSRC}/docs && ${GMAKE} man && \
77
	${INSTALL_MAN} offlineimapui.7 ${STAGEDIR}${MAN7PREFIX}/man/man7/ && \
78
	${INSTALL_MAN} offlineimap.1 ${STAGEDIR}${MAN1PREFIX}/man/man1/
79
80
post-install-EXAMPLES-on:
81
	${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
82
	${INSTALL_DATA} ${WRKSRC}/offlineimap.conf ${STAGEDIR}${EXAMPLESDIR}
83
84
do-test:
85
	@cd ${WRKSRC} && \
86
	${CP} test/credentials.conf.sample test/credentials.conf && \
87
	${PYTHON_CMD} -m pytest -v -rs -o addopts= test/
88
89
.include <bsd.port.mk>
(-)b/mail/py-offlineimap3/distinfo (+3 lines)
Added Link Here
1
TIMESTAMP = 1645914524
2
SHA256 (OfflineIMAP-offlineimap3-v8.0.0_GH0.tar.gz) = 5d40c163ca2fbf89658116e29f8fa75050d0c34c29619019eee1a84c90fcab32
3
SIZE (OfflineIMAP-offlineimap3-v8.0.0_GH0.tar.gz) = 702509
(-)b/mail/py-offlineimap3/files/patch-offlineimap_imapserver.py (+11 lines)
Added Link Here
1
--- offlineimap/imapserver.py.orig	2022-02-27 05:55:01 UTC
2
+++ offlineimap/imapserver.py
3
@@ -879,7 +879,7 @@ class IdleThread:
4
             while not success:
5
                 imapobj = self.parent.acquireconnection()
6
                 try:
7
-                    imapobj.select(self.folder)
8
+                    imapobj.select(imaputil.foldername_to_imapname(self.folder))
9
                 except OfflineImapError as e:
10
                     if e.severity == OfflineImapError.ERROR.FOLDER_RETRY:
11
                         # Connection closed, release connection and retry.
(-)b/mail/py-offlineimap3/files/patch-test_tests_test__01__basic.py (+59 lines)
Added Link Here
1
--- test/tests/test_01_basic.py.orig	2022-03-04 03:43:46 UTC
2
+++ test/tests/test_01_basic.py
3
@@ -17,6 +17,8 @@ import unittest
4
 import logging
5
 from test.OLItest import OLITestLib
6
 
7
+import pytest
8
+
9
 # Things need to be setup first, usually setup.py initializes everything.
10
 # but if e.g. called from command line, we take care of default values here:
11
 if not OLITestLib.cred_file:
12
@@ -47,6 +49,7 @@ class TestBasicFunctions(unittest.TestCase):
13
     def tearDown(self):
14
         OLITestLib.delete_remote_testfolders()
15
 
16
+    @pytest.mark.skip(reason="skpping test needs remote auth")
17
     def test_01_olistartup(self):
18
         """Tests if OLI can be invoked without exceptions
19
 
20
@@ -60,6 +63,7 @@ class TestBasicFunctions(unittest.TestCase):
21
                             "mails, but sync led to {0} folders and {1} mails"
22
                         .format(boxes, mails))
23
 
24
+    @pytest.mark.skip(reason="skpping test needs remote auth")
25
     def test_02_createdir(self):
26
         """Create local 'OLItest 1', sync"""
27
         OLITestLib.delete_maildir('')  # Delete all local maildir folders
28
@@ -71,6 +75,7 @@ class TestBasicFunctions(unittest.TestCase):
29
                             "mails, but sync led to {0} folders and {1} mails"
30
                         .format(boxes, mails))
31
 
32
+    @pytest.mark.skip(reason="skpping test needs remote auth")
33
     def test_03_createdir_quote(self):
34
         """Create local 'OLItest "1"' maildir, sync
35
 
36
@@ -87,6 +92,7 @@ class TestBasicFunctions(unittest.TestCase):
37
                             "mails, but sync led to {0} folders and {1} mails"
38
                         .format(boxes, mails))
39
 
40
+    @pytest.mark.skip(reason="skpping test needs remote auth")
41
     def test_04_nametransmismatch(self):
42
         """Create mismatching remote and local nametrans rules
43
 
44
@@ -108,6 +114,7 @@ class TestBasicFunctions(unittest.TestCase):
45
         # Write out default config file again
46
         OLITestLib.write_config_file()
47
 
48
+    @pytest.mark.skip(reason="skpping test needs remote auth")
49
     def test_05_createmail(self):
50
         """Create mail in OLItest 1, sync, wipe folder sync
51
 
52
@@ -133,6 +140,7 @@ class TestBasicFunctions(unittest.TestCase):
53
                              "assigned the IMAP's UID number, but {0} messages had no valid ID "
54
                          .format(len([None for x in uids if x is None])))
55
 
56
+    @pytest.mark.skip(reason="skpping test needs remote auth")
57
     def test_06_createfolders(self):
58
         """Test if createfolders works as expected
59
 
(-)b/mail/py-offlineimap3/pkg-descr (-1 / +4 lines)
Added Link Here
0
- 
1
OfflineIMAP is software that downloads your email mailbox(es) as
2
local Maildirs. OfflineIMAP will synchronize both sides via IMAP.
3
4
WWW: https://github.com/OfflineIMAP/offlineimap3

Return to bug 262233