[arch-commits] Commit in python-moto/trunk (PKGBUILD)

Chih-Hsuan Yen yan12125 at gemini.archlinux.org
Fri Aug 20 08:34:21 UTC 2021


    Date: Friday, August 20, 2021 @ 08:34:20
  Author: yan12125
Revision: 1003964

upgpkg: python-moto 2.2.3-1

Ref: https://github.com/spulec/moto/pull/4142

Modified:
  python-moto/trunk/PKGBUILD

----------+
 PKGBUILD |   14 ++++++++++----
 1 file changed, 10 insertions(+), 4 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2021-08-20 08:31:10 UTC (rev 1003963)
+++ PKGBUILD	2021-08-20 08:34:20 UTC (rev 1003964)
@@ -3,18 +3,20 @@
 
 pkgname=python-moto
 _pkgname=moto
-pkgver=2.2.1
+pkgver=2.2.3
 pkgrel=1
 pkgdesc='Moto is a library to mock out the boto library.'
 arch=(any)
 url='https://github.com/spulec/moto'
 license=(Apache)
-# depends on python-setuptools as pkg_resources is used is several modules
 # NOTE: Keep the order of dependencies matching setup.py
+# setup.py includes setuptools, which is a work around for missing dependencies in aws-xray-sdk [1].
+# I use the correct dependency in python-aws-xray-sdk, so python-setuptools is not needed here.
+# [1] https://github.com/spulec/moto/pull/4142
 depends=(python-boto3 python-botocore python-cryptography python-requests python-xmltodict
          python-werkzeug python-pytz python-dateutil python-responses
          # Below dependencies varied with Python versions
-         python-jinja python-more-itertools python-setuptools)
+         python-jinja python-more-itertools)
 # See reqquirements-test.txt, excluding pytest-cov
 checkdepends=(python-pytest python-sure python-freezegun
               # boto is vendored (#3503), but still imported in tests
@@ -39,7 +41,7 @@
                python-cfn-lint python-sshpubkeys python-flask python-flask-cors)
 source=("https://files.pythonhosted.org/packages/source/m/moto/moto-${pkgver}.tar.gz"
         sdist-no-pyc.diff)
-sha256sums=('4ea538fe090b964c22bb98a6f87d3c589eaf754893d297d58b74dedb94d4448c'
+sha256sums=('76850f44a38c0047e573ec5d4d2e5b20a77ae2de2691b2be03ed0cae17a85a0e'
             '4193bd88380f6ab8dac49be37d940993dee4e31351ffd60c8167b7c8e5ec3208')
 
 prepare() {
@@ -50,6 +52,10 @@
   # Remove upper bounds of dependencies
   sed --in-place=.orig -r 's#,?<[0-9.]+,?##;s#==([0-9.]+)#>=\1#' setup.py
   diff -u setup.py{.orig,} || true
+
+  # Remove the unnecessary dependency. See also https://bugs.archlinux.org/task/64719
+  sed -i '/"importlib_metadata"/d' setup.py
+  sed -i 's#importlib_metadata#importlib.metadata#g' moto/core/models.py
 }
 
 build() {



More information about the arch-commits mailing list