svn commit: r457227 - in head/devel: . py-deprecation
Sunpoet Po-Chuan Hsieh
sunpoet at FreeBSD.org
Mon Dec 25 13:53:23 UTC 2017
Author: sunpoet
Date: Mon Dec 25 13:53:21 2017
New Revision: 457227
URL: https://svnweb.freebsd.org/changeset/ports/457227
Log:
Add py-deprecation 1.0.1
The deprecation library provides a deprecated decorator and a
fail_if_not_removed decorator for your tests. Together, the two enable the
automation of several things:
- The docstring of a deprecated method gets the deprecation details appended to
the end of it. If you generate your API docs direct from your source, you
don't need to worry about writing your own notification. You also don't need
to worry about forgetting to write it. It's done for you.
- Rather than having code live on forever because you only deprecated it but
never actually moved on from it, you can have your tests tell you when it's
time to remove the code. The @deprecated decorator can be told when it's time
to entirely remove the code, which causes @fail_if_not_removed to raise an
AssertionError, causing either your unittest or py.test tests to fail.
WWW: https://pypi.python.org/pypi/deprecation
WWW: https://github.com/briancurtin/deprecation
Added:
head/devel/py-deprecation/
head/devel/py-deprecation/Makefile (contents, props changed)
head/devel/py-deprecation/distinfo (contents, props changed)
head/devel/py-deprecation/pkg-descr (contents, props changed)
Modified:
head/devel/Makefile
Modified: head/devel/Makefile
==============================================================================
--- head/devel/Makefile Mon Dec 25 13:24:19 2017 (r457226)
+++ head/devel/Makefile Mon Dec 25 13:53:21 2017 (r457227)
@@ -4374,6 +4374,7 @@
SUBDIR += py-delfick_error
SUBDIR += py-deliciousapi
SUBDIR += py-demjson
+ SUBDIR += py-deprecation
SUBDIR += py-dexml
SUBDIR += py-dialog
SUBDIR += py-diazo
Added: head/devel/py-deprecation/Makefile
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/devel/py-deprecation/Makefile Mon Dec 25 13:53:21 2017 (r457227)
@@ -0,0 +1,20 @@
+# Created by: Po-Chuan Hsieh <sunpoet at FreeBSD.org>
+# $FreeBSD$
+
+PORTNAME= deprecation
+PORTVERSION= 1.0.1
+CATEGORIES= devel python
+MASTER_SITES= CHEESESHOP
+PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER= sunpoet at FreeBSD.org
+COMMENT= Library to handle automated deprecations
+
+LICENSE= APACHE20
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+NO_ARCH= yes
+USE_PYTHON= autoplist distutils
+USES= python
+
+.include <bsd.port.mk>
Added: head/devel/py-deprecation/distinfo
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/devel/py-deprecation/distinfo Mon Dec 25 13:53:21 2017 (r457227)
@@ -0,0 +1,3 @@
+TIMESTAMP = 1514205418
+SHA256 (deprecation-1.0.1.tar.gz) = b9bff5cc91f601ef2a8a0200bc6cde3f18a48c2ed3d1ecbfc16076b14b3ad935
+SIZE (deprecation-1.0.1.tar.gz) = 9596
Added: head/devel/py-deprecation/pkg-descr
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/devel/py-deprecation/pkg-descr Mon Dec 25 13:53:21 2017 (r457227)
@@ -0,0 +1,15 @@
+The deprecation library provides a deprecated decorator and a
+fail_if_not_removed decorator for your tests. Together, the two enable the
+automation of several things:
+- The docstring of a deprecated method gets the deprecation details appended to
+ the end of it. If you generate your API docs direct from your source, you
+ don't need to worry about writing your own notification. You also don't need
+ to worry about forgetting to write it. It's done for you.
+- Rather than having code live on forever because you only deprecated it but
+ never actually moved on from it, you can have your tests tell you when it's
+ time to remove the code. The @deprecated decorator can be told when it's time
+ to entirely remove the code, which causes @fail_if_not_removed to raise an
+ AssertionError, causing either your unittest or py.test tests to fail.
+
+WWW: https://pypi.python.org/pypi/deprecation
+WWW: https://github.com/briancurtin/deprecation
More information about the svn-ports-all
mailing list