diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 0000000..6ce55a3 --- /dev/null +++ b/debian/changelog @@ -0,0 +1,5 @@ +backoff (1.10.0-0kali1) kali-dev; urgency=medium + + * Initial release + + -- Sophie Brun Wed, 16 Dec 2020 14:41:30 +0100 diff --git a/debian/control b/debian/control new file mode 100644 index 0000000..05bcd91 --- /dev/null +++ b/debian/control @@ -0,0 +1,28 @@ +Source: backoff +Section: python +Priority: optional +Maintainer: Kali Developers +Uploaders: Sophie Brun +Build-Depends: debhelper-compat (= 13), dh-python, python3-setuptools, python3-all, python3-pytest, python3-pytest-asyncio +Standards-Version: 4.5.1 +Homepage: https://github.com/litl/backoff +Vcs-Browser: https://gitlab.com/kalilinux/packages/backoff +Vcs-Git: https://gitlab.com/kalilinux/packages/backoff.git +Testsuite: autopkgtest-pkg-python +Rules-Requires-Root: no + +Package: python3-backoff +Architecture: all +Depends: ${python3:Depends}, ${misc:Depends} +Description: Function decoration for backoff and retry (Python 3) + This package provides function decorators which can be used to wrap a function + such that it will be retried until some condition is met. It is meant to be of + use when accessing unreliable resources with the potential for intermittent + failures i.e. network resources and external APIs. Somewhat more generally, it + may also be of use for dynamically polling resources for externally generated + content. + . + Decorators support both regular functions for synchronous code and asyncio's + coroutines for asynchronous code. + . + This package installs the library for Python 3. diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 0000000..423e89b --- /dev/null +++ b/debian/copyright @@ -0,0 +1,31 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: backoff +Source: https://github.com/litl/backoff + +Files: * +Copyright: 2014 litl, LLC. +License: MIT + +Files: debian/* +Copyright: 2020 Sophie Brun +License: MIT + +License: MIT + Permission is hereby granted, free of charge, to any person obtaining a + copy of this software and associated documentation files (the + "Software"), to deal in the Software without restriction, including + without limitation the rights to use, copy, modify, merge, publish, + distribute, sublicense, and/or sell copies of the Software, and to permit + persons to whom the Software is furnished to do so, subject to the + following conditions: + . + The above copyright notice and this permission notice shall be included + in all copies or substantial portions of the Software. + . + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN + NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, + DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR + OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE + USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/debian/patches/Add-missing-setup.py.patch b/debian/patches/Add-missing-setup.py.patch new file mode 100644 index 0000000..6d9f89c --- /dev/null +++ b/debian/patches/Add-missing-setup.py.patch @@ -0,0 +1,43 @@ +From: Sophie Brun +Date: Wed, 16 Dec 2020 16:16:09 +0100 +Subject: Add missing setup.py + +Forwarded: not-needed +The package uses poetry to generate a setup.py +Poetry is not yet in Debian. We copy the generated setup.py (from pypi +tarball) +--- + setup.py | 24 ++++++++++++++++++++++++ + 1 file changed, 24 insertions(+) + create mode 100644 setup.py + +diff --git a/setup.py b/setup.py +new file mode 100644 +index 0000000..6e4f961 +--- /dev/null ++++ b/setup.py +@@ -0,0 +1,24 @@ ++# -*- coding: utf-8 -*- ++from distutils.core import setup ++ ++packages = \ ++['backoff'] ++ ++package_data = \ ++{'': ['*']} ++ ++setup_kwargs = { ++ 'name': 'backoff', ++ 'version': '1.10.0', ++ 'description': 'Function decoration for backoff and retry', ++ 'long_description': 'Function decoration for backoff and retry. This module provides function decorators which can be used to wrap a\nfunction such that it will be retried until some condition is met. It\nis meant to be of use when accessing unreliable resources with the\npotential for intermittent failures i.e. network resources and external\nAPIs. Somewhat more generally, it may also be of use for dynamically\npolling resources for externally generated content.\n\nDecorators support both regular functions for synchronous code and\n`asyncio\'s coroutines\nfor asynchronous code.', ++ 'author': 'Bob Green', ++ 'author_email': 'rgreen@goscoutgo.com', ++ 'url': 'https://github.com/litl/backoff', ++ 'packages': packages, ++ 'package_data': package_data, ++ 'python_requires': '>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*', ++} ++ ++ ++setup(**setup_kwargs) diff --git a/debian/patches/series b/debian/patches/series new file mode 100644 index 0000000..2940366 --- /dev/null +++ b/debian/patches/series @@ -0,0 +1 @@ +Add-missing-setup.py.patch diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..dd1ca57 --- /dev/null +++ b/debian/rules @@ -0,0 +1,9 @@ +#!/usr/bin/make -f +# See debhelper(7) (uncomment to enable) +# output every command that modifies files on the build system. +#export DH_VERBOSE = 1 + +export PYBUILD_NAME=backoff + +%: + dh $@ --with python3 --buildsystem=pybuild diff --git a/debian/source/format b/debian/source/format new file mode 100644 index 0000000..163aaf8 --- /dev/null +++ b/debian/source/format @@ -0,0 +1 @@ +3.0 (quilt) diff --git a/debian/source/options b/debian/source/options new file mode 100644 index 0000000..cb61fa5 --- /dev/null +++ b/debian/source/options @@ -0,0 +1 @@ +extend-diff-ignore = "^[^/]*[.]egg-info/" diff --git a/debian/watch b/debian/watch new file mode 100644 index 0000000..ede2f9b --- /dev/null +++ b/debian/watch @@ -0,0 +1,4 @@ +version=4 +opts="filenamemangle=s%(?:.*?)?v?(\d[\d.]*)\.tar\.gz%backoff-$1.tar.gz%" \ + https://github.com/litl/backoff/tags \ + (?:.*?/)?v?(\d[\d.]*)\.tar\.gz debian uupdate