Created attachment 185857 [details] Adds port for py-treq An HTTP library inspired by requests but written on top of Twisted's Agents. It provides a simple, higher level API for making HTTP requests when using Twisted. WWW: https://github.com/twisted/treq
Looks OK, a few considerations: - Ideally, MAINTAINER for new ports should be author unless compelling reason not to be. python is happy to be a fallback in the case of maintainers falling away over time however. - Consider invoking trial via "${PYTHON_CMD} -m <something.trial|trial.something>" rather than localbase scripts, which cannot be relied upon to point to the same/expected version of Python over time (users can change 'default' version of python at any time). - Add LICENSE_FILE if one exists (or is provided by) in WKRSRC (extracted tarball). One is provided (named LICENSE) - Upstream 'Trove classifiers' specify 2.7+ support (2.7,3.3+ precisely), but USES=python is limited to -2.7: "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", - install_requires depends explicitly on "Twisted[tls] >= 16.4.0", you may want this port to depend 'explicitly' on those optional 'tls' python packages to ensure they're installed (the twisted port may or may not install them, as they're, well, optional) Confirmation of QA also not provided
Created attachment 186213 [details] Address koob's feedback This should address all of your concerns: 1) changed maintainer to myself 2) Invoke trial the way you suggest 3) Add LICENSE_FILE 4) Change the python dependency to 2.7+. I couldn't find a way to do 2.7+,3.3+, but hopefully nobody still has 3.0-3.2 lying around. 5) Made the twisted[tls] dependencies into mandatory dependencies of py-treq, even though not all py-treq consumers use them (buildbot, for example, does not). But setup.py considers Twisted TLS support to be mandatory. Tested it by: 1) Building in Poudriere 2) Running Buildbot on a jail with py-treq installed instead of py-txrequests 3) Running "make test" in an interactive Poudriere session. Some tests fail, but they look like code problems, beyond the ken of a packager like myself. This step did reveal a separate problem, though, addressed in PR 222181.
I might split out the twisted[tls] dependencies [1] into a separate/additional RUN_DEPENDS section with a comment, so our future selves know the context/special treatment of those deps: # Depend directly on twisted[tls] dependencies # As Twisted port may not (optionally) install them RUN_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}openssl>=16.0.0:security/py-openssl \ ${PYTHON_PKGNAMEPREFIX}service_identity>=16.0.0:security/py-service_identity \ ${PYTHON_PKGNAMEPREFIX}idna>=2.4:dns/py-idna [1] https://github.com/twisted/twisted/blob/trunk/src/twisted/python/_setup.py#L93 Other than that the change looks OK.
A commit references this bug: Author: asomers Date: Sun Sep 17 04:13:50 UTC 2017 New revision: 449983 URL: https://svnweb.freebsd.org/changeset/ports/449983 Log: new port: www/py-treq Requests-like API built on top of twisted.web's Agent PR: 221889 Reviewed by: koobs Approved by: koobs (portmgr) Changes: head/www/Makefile head/www/py-treq/ head/www/py-treq/Makefile head/www/py-treq/distinfo head/www/py-treq/pkg-descr
Comment on attachment 186213 [details] Address koob's feedback Clearly/correctly document approval: Approved by: koobs (ports)