Bug 248633 - [NEW PORT] mail/getmail6: POP3/IMAP4 mail retriever with Maildir and command delivery (python3 fork)
Summary: [NEW PORT] mail/getmail6: POP3/IMAP4 mail retriever with Maildir and command ...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords: feature, needs-qa
Depends on:
Blocks:
 
Reported: 2020-08-12 20:04 UTC by Michael Bueker
Modified: 2020-08-18 19:13 UTC (History)
3 users (show)

See Also:
koobs: maintainer-feedback+


Attachments
Makefile (1007 bytes, text/plain)
2020-08-12 20:04 UTC, Michael Bueker
no flags Details
distinfo (195 bytes, text/plain)
2020-08-12 20:05 UTC, Michael Bueker
no flags Details
pkg-descr (1.08 KB, text/plain)
2020-08-12 20:05 UTC, Michael Bueker
no flags Details
pkg-message (204 bytes, text/plain)
2020-08-12 20:06 UTC, Michael Bueker
no flags Details
pkg-plist (2.55 KB, text/plain)
2020-08-12 20:06 UTC, Michael Bueker
no flags Details
files/patch-setup.py (1.03 KB, patch)
2020-08-12 20:06 UTC, Michael Bueker
no flags Details | Diff
ports tree patch for new port mail/getmail6 (4.83 KB, patch)
2020-08-13 12:15 UTC, Michael Bueker
no flags Details | Diff
ports tree patch for new port mail/getmail6 (4.84 KB, patch)
2020-08-13 14:28 UTC, Michael Bueker
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Bueker 2020-08-12 20:04:20 UTC
getmail-5.14 depends on python-2.7, and there is no upstream effort to port to python3. If nothing happens, getmail will soon (EXPIRATION_DATE=2020-09-15) fall out of the ports tree without any replacement.

Fortunetely, a fork ported to python3 has recently been published. It lives at: https://github.com/getmail6/getmail6/

The first release (6.02) has just been tagged. I have created a port that compiles, installs and runs on my system (11.4-p2) without problems. I suggest that a new port named mail/getmail6 be added to the ports tree, and users encouraged to migrate to it from mail/getmail upon expiration.

Please find the Makefile etc attached. As my experience in port maintenance is very limited, I'd appreciate someone checking on it.
Comment 1 Michael Bueker 2020-08-12 20:04:59 UTC
Created attachment 217174 [details]
Makefile
Comment 2 Michael Bueker 2020-08-12 20:05:20 UTC
Created attachment 217175 [details]
distinfo
Comment 3 Michael Bueker 2020-08-12 20:05:43 UTC
Created attachment 217176 [details]
pkg-descr
Comment 4 Michael Bueker 2020-08-12 20:06:00 UTC
Created attachment 217177 [details]
pkg-message
Comment 5 Michael Bueker 2020-08-12 20:06:16 UTC
Created attachment 217178 [details]
pkg-plist
Comment 6 Michael Bueker 2020-08-12 20:06:32 UTC
Created attachment 217179 [details]
files/patch-setup.py
Comment 7 Kubilay Kocak freebsd_committer freebsd_triage 2020-08-13 04:25:03 UTC
Thank you for the report and patches Michael.

Can you confirm the port passes QA (there's some things that need changing) and provide the updated submission as a single unified diff (svn diff or diff -u) against the ports root dir please, thank you!

Some review items:

 - Use USE_PYTHON autoplist and concurrent
 - Sort/group USES/USE_*
 - Update python:<version-spec> to declare all versions it supports. If it still supports 2.x, USES=python is fine
 - Use DISTVERSIONPREFIX instead of vXX in GH_TAGNAME
 - Unset MASTER_SITES
 - Set MAINTAINER

^Triage: Since this is a new port, reset Assignee, keeping existing getmail MAINTAINER cc'd, in case they want to maintain and/or commit this
Comment 8 Michael Bueker 2020-08-13 12:14:21 UTC
Thanks for your guidance. I'm attaching an updated patch:

- it's a unified diff against the ports tree now
- USES/USE_* is grouped
- USE_PYTHON=autoplist distutils concurrent (and pkg-plist removed)
- USES=python (upstream says 2.7 is supported, haven't tested)
- DISTVERSION=6.02 and DISTVERSIONPREFIX=v (and distinfo updated)
- MASTER_SITES removed
- set the original MAINTAINER of mail/getmail for the time being

The port still builds, installs and runs fine on my box with 11.4-RELEASE-p2 and python3.7.

Is there some other QA checklist I should consider? My capabilities for testing are unfortunately limited.
Comment 9 Michael Bueker 2020-08-13 12:15:04 UTC
Created attachment 217192 [details]
ports tree patch for new port mail/getmail6
Comment 10 Kubilay Kocak freebsd_committer freebsd_triage 2020-08-13 12:24:09 UTC
Thanks for the update Michael

Our canonical testing processes and instructions can be found here:

https://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/porting-testing.html

In the absence of poudriere QA (highly recommended/encouraged), the steps outlined in "Procedure 3.1" are OK.
Comment 11 Michael Bueker 2020-08-13 12:53:55 UTC
Thank you for that link. I've tested according to the "Procedure 3.1", since poudriere is currently not available to me. There are two problems:

1) make stage-qa fails:
Error: Package names are not unique with flavors:
py37: getmail6-6.02
py27: getmail6-6.02
Error: maybe use <flavor>_PKGNAMEPREFIX/SUFFIX.

I'm not sure what to do about this. stage-qa passes if I set USES=python:3.7. That seems reasonable to me, since python3 support is the whole point of having this port, and python2 will be deprecrated soon. On the other hand, since 2.7 is supported according to upstream, that wouldn't be entirely accurate.

2) make package as user fails with "Permission denied" errors (even for users in the wheel group).

Also, I don't know what to do about this. The permissions of the port dir/files look the same as with other ports.
Comment 12 Kubilay Kocak freebsd_committer freebsd_triage 2020-08-13 13:11:44 UTC
(In reply to Michael Bueker from comment #11)

For the first issue:

  Add PKGNAMEPREFIX=${PYTHON_PKGNAMEPREFIX}

I'm not sure about the second, and could be a local issue (poudriere would isolate this).

This should be good to go
Comment 13 Michael Bueker 2020-08-13 14:28:47 UTC
Created attachment 217194 [details]
ports tree patch for new port mail/getmail6

PKGNAMEPREFIX=${PYTHON_PKGNAMEPREFIX} added, make stage-qa now passes without warnings
Comment 14 Joseph Mingrone freebsd_committer 2020-08-13 15:32:24 UTC
Thanks for submitting.  I've made some tweaks to conform to style guides in the Porter's Handbook and added you as maintainer (tag, you're it).

https://reviews.freebsd.org/D26057

I've also run it through portlint/portclippy/portfmt and poudriere and everything now looks good.
Comment 15 Joseph Mingrone freebsd_committer 2020-08-13 16:10:01 UTC
Michael, of course, if you are not interested in being a maintainer, just say and I'll make changes.  I didn't see a Phabricator account for you, so you can just suggest any changes here.  If you do create a Phab account, let me know and I can add you as a reviewer there.
Comment 16 Michael Bueker 2020-08-13 16:18:22 UTC
I suppose I'll grow into it ;) Thanks for the consideration!
Comment 17 commit-hook freebsd_committer 2020-08-18 19:11:43 UTC
A commit references this bug:

Author: jrm
Date: Tue Aug 18 19:10:45 UTC 2020
New revision: 545250
URL: https://svnweb.freebsd.org/changeset/ports/545250

Log:
  New port, mail/getmail6: A python3 fork of mail/getmail

  PR:		248633
  Submitted by:	Michael Bueker <m.bueker@berlin.de> (maintainer)
  Reviewed by:	koobs
  Differential Revision:	https://reviews.freebsd.org/D26057

Changes:
  head/mail/Makefile
  head/mail/getmail6/
  head/mail/getmail6/Makefile
  head/mail/getmail6/distinfo
  head/mail/getmail6/files/
  head/mail/getmail6/files/patch-setup.py
  head/mail/getmail6/pkg-descr
  head/mail/getmail6/pkg-message
Comment 18 Joseph Mingrone freebsd_committer 2020-08-18 19:13:10 UTC
Committed.  Thanks for submitting.

Joe