Date: Thursday, April 13, 2023 @ 03:17:40
Author: felixonmars
Revision: 1445074
archrelease: copy trunk to community-staging-any
Added:
python-boto/repos/community-staging-any/
python-boto/repos/community-staging-any/PKGBUILD
(from rev 1445073, python-boto/trunk/PKGBUILD)
python-boto/repos/community-staging-any/boto-python-3.11-mock.patch
(from rev 1445073, python-boto/trunk/boto-python-3.11-mock.patch)
python-boto/repos/community-staging-any/boto-python-3.8.patch
(from rev 1445073, python-boto/trunk/boto-python-3.8.patch)
python-boto/repos/community-staging-any/unittest-mock.patch
(from rev 1445073, python-boto/trunk/unittest-mock.patch)
-----------------------------+
PKGBUILD | 49 +++++++
boto-python-3.11-mock.patch | 22 +++
boto-python-3.8.patch | 58 ++++++++
unittest-mock.patch | 292 ++++++++++++++++++++++++++++++++++++++++++
4 files changed, 421 insertions(+)
Copied: python-boto/repos/community-staging-any/PKGBUILD (from rev 1445073,
python-boto/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD (rev 0)
+++ community-staging-any/PKGBUILD 2023-04-13 03:17:40 UTC (rev 1445074)
@@ -0,0 +1,49 @@
+# Maintainer: Felix Yan <[email protected]>
+# Contributor: Kaiting Chen <[email protected]>
+# Contributor: Aaron Schaefer <[email protected]>
+
+pkgname=python-boto
+pkgver=2.49.0.20190327
+_commit=9e1cd3bd76e738d80630f1bd9160fd87c8eab865
+pkgrel=9
+pkgdesc='A Python interface to Amazon Web Services (AWS)'
+arch=('any')
+url='https://github.com/boto/boto'
+license=('MIT')
+depends=('python')
+makedepends=('python-setuptools')
+checkdepends=('python-nose' 'python-requests' 'python-httpretty')
+source=("$pkgname-$_commit.tar.gz::https://github.com/boto/boto/archive/$_commit.tar.gz"
+ boto-python-3.10.patch::https://github.com/boto/boto/pull/3898.patch
+ boto-python-3.8.patch
+ boto-python-3.11-mock.patch
+ unittest-mock.patch)
+sha512sums=('a68b7560caef3328970b9d1febc77fb28e537e4012b692b492d69428aca7deccf539e883cba4975497059ccdc56452f6e46f4a101b6e93f007667fe45c842e24'
+
'86c1318781832dad8e45f5a0168fe338f0c3dd168568342055191db68779caa8af04a4e11357a37e6b47adb132f9dccfd6e2e4df96d59ebb71db4e6073a625ba'
+
'3e32db201adb637d3b6041f9e7be65889f1306042cbed36e4884207cbf772dc8f7691be9a505ec79f111b99c8313e0d42436c1f9a2dfa095de6cc77a7fe4bc6d'
+
'5b3d8cfa74e0996ffbe467080f48241b5ea90801f738702b5845f53b68d692981a994bccaccbcd70e455bea934d246f441106293e4602e93f594c53254e13584'
+
'8179486e67a9224fee9fa9b2a39a3eb6a80226d9bf1cff20cef1b34f4d85dc1589cd4d263cc8e0c6f6f6b9776957de98c2e641c1260eff926d266a223766a4b5')
+
+prepare() {
+ mv boto-{$_commit,$pkgver}
+ cd boto-$pkgver
+ patch -p1 -i ../boto-python-3.8.patch # Fix escaping with python 3.8
+ patch -p1 -i ../boto-python-3.10.patch # Fix collections.abc imports
+ patch -p1 -i ../unittest-mock.patch # Stop using python-mock
+ patch -p1 -i ../boto-python-3.11-mock.patch # Fix mock for python 3.11
+}
+
+check() {
+ cd "$srcdir"/boto-$pkgver
+ python tests/test.py default
+}
+
+package() {
+ cd boto-$pkgver
+
+ python setup.py install -O1 --root="$pkgdir"
+ install -D -m644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+
+ # Remove (somewhat deprecated) python 2 tools.
+ rm -r "$pkgdir"/usr/bin
+}
Copied: python-boto/repos/community-staging-any/boto-python-3.11-mock.patch
(from rev 1445073, python-boto/trunk/boto-python-3.11-mock.patch)
===================================================================
--- community-staging-any/boto-python-3.11-mock.patch
(rev 0)
+++ community-staging-any/boto-python-3.11-mock.patch 2023-04-13 03:17:40 UTC
(rev 1445074)
@@ -0,0 +1,22 @@
+diff --git a/tests/unit/ec2/test_volume.py b/tests/unit/ec2/test_volume.py
+index 81d7f552..6833c763 100644
+--- a/tests/unit/ec2/test_volume.py
++++ b/tests/unit/ec2/test_volume.py
+@@ -3,6 +3,7 @@ from tests.compat import mock, unittest
+ from boto.ec2.snapshot import Snapshot
+ from boto.ec2.tag import Tag, TagSet
+ from boto.ec2.volume import Volume, AttachmentSet, VolumeAttribute
++from boto.resultset import ResultSet
+
+
+ class VolumeTests(unittest.TestCase):
+@@ -52,8 +53,7 @@ class VolumeTests(unittest.TestCase):
+ self.assertEqual(retval, tag_set)
+
+ @mock.patch("boto.ec2.volume.TaggedEC2Object.startElement")
+- @mock.patch("boto.resultset.ResultSet")
+- def test_startElement_with_name_tagSet_calls_ResultSet(self, ResultSet,
startElement):
++ def test_startElement_with_name_tagSet_calls_ResultSet(self,
startElement):
+ startElement.return_value = None
+ result_set = mock.Mock(ResultSet([("item", Tag)]))
+ volume = Volume()
Copied: python-boto/repos/community-staging-any/boto-python-3.8.patch (from rev
1445073, python-boto/trunk/boto-python-3.8.patch)
===================================================================
--- community-staging-any/boto-python-3.8.patch (rev 0)
+++ community-staging-any/boto-python-3.8.patch 2023-04-13 03:17:40 UTC (rev
1445074)
@@ -0,0 +1,58 @@
+diff --git a/boto/ecs/item.py b/boto/ecs/item.py
+index 79177a31..a9504e9d 100644
+--- a/boto/ecs/item.py
++++ b/boto/ecs/item.py
+@@ -21,7 +21,11 @@
+
+
+ import xml.sax
+-import cgi
++try:
++ from html import escape as html_escape
++except ImportError:
++ # Python 2
++ from cgi import escape as html_escape
+ from boto.compat import six, StringIO
+
+ class ResponseGroup(xml.sax.ContentHandler):
+@@ -67,7 +71,7 @@ class ResponseGroup(xml.sax.ContentHandler):
+ return None
+
+ def endElement(self, name, value, connection):
+- self._xml.write("%s</%s>" % (cgi.escape(value).replace("&amp;",
"&"), name))
++ self._xml.write("%s</%s>" % (html_escape(value).replace("&amp;",
"&"), name))
+ if len(self._nodepath) == 0:
+ return
+ obj = None
+diff --git a/tests/unit/utils/test_utils.py b/tests/unit/utils/test_utils.py
+index db15b56d..d2e8dfb3 100644
+--- a/tests/unit/utils/test_utils.py
++++ b/tests/unit/utils/test_utils.py
+@@ -85,7 +85,7 @@ class TestPassword(unittest.TestCase):
+ def hmac_hashfunc(cls, msg):
+ if not isinstance(msg, bytes):
+ msg = msg.encode('utf-8')
+- return hmac.new(b'mysecretkey', msg)
++ return hmac.new(b'mysecretkey', msg, digestmod=hashlib.md5)
+
+ class HMACPassword(Password):
+ hashfunc = hmac_hashfunc
+@@ -95,15 +95,15 @@ class TestPassword(unittest.TestCase):
+ password.set('foo')
+
+ self.assertEquals(str(password),
+- hmac.new(b'mysecretkey', b'foo').hexdigest())
++ hmac.new(b'mysecretkey', b'foo',
digestmod=hashlib.md5).hexdigest())
+
+ def test_constructor(self):
+- hmac_hashfunc = lambda msg: hmac.new(b'mysecretkey', msg)
++ hmac_hashfunc = lambda msg: hmac.new(b'mysecretkey', msg,
digestmod=hashlib.md5)
+
+ password = Password(hashfunc=hmac_hashfunc)
+ password.set('foo')
+ self.assertEquals(password.str,
+- hmac.new(b'mysecretkey', b'foo').hexdigest())
++ hmac.new(b'mysecretkey', b'foo',
digestmod=hashlib.md5).hexdigest())
+
+
+ class TestPythonizeName(unittest.TestCase):
Copied: python-boto/repos/community-staging-any/unittest-mock.patch (from rev
1445073, python-boto/trunk/unittest-mock.patch)
===================================================================
--- community-staging-any/unittest-mock.patch (rev 0)
+++ community-staging-any/unittest-mock.patch 2023-04-13 03:17:40 UTC (rev
1445074)
@@ -0,0 +1,292 @@
+diff -aur boto-2.49.0.20190327/requirements.txt
boto-2.49.0.20190327.new/requirements.txt
+--- boto-2.49.0.20190327/requirements.txt 2019-03-27 02:07:03.000000000
+0100
++++ boto-2.49.0.20190327.new/requirements.txt 2022-11-12 17:45:21.295229358
+0100
+@@ -7,4 +7,3 @@
+ paramiko>=1.10.0
+ PyYAML>=3.10
+ coverage==3.7.1
+-mock==1.0.1
+diff -aur boto-2.49.0.20190327/tests/integration/s3/test_bucket.py
boto-2.49.0.20190327.new/tests/integration/s3/test_bucket.py
+--- boto-2.49.0.20190327/tests/integration/s3/test_bucket.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/integration/s3/test_bucket.py
2022-11-12 17:45:37.645593701 +0100
+@@ -26,7 +26,7 @@
+ Some unit tests for the S3 Bucket
+ """
+
+-from mock import patch, Mock
++from unittest.mock import patch, Mock
+ import unittest
+ import time
+
+diff -aur
boto-2.49.0.20190327/tests/integration/s3/test_https_cert_validation.py
boto-2.49.0.20190327.new/tests/integration/s3/test_https_cert_validation.py
+--- boto-2.49.0.20190327/tests/integration/s3/test_https_cert_validation.py
2019-03-27 02:07:03.000000000 +0100
++++
boto-2.49.0.20190327.new/tests/integration/s3/test_https_cert_validation.py
2022-11-12 17:57:21.673791221 +0100
+@@ -38,7 +38,7 @@
+ import os
+ import ssl
+ import unittest
+-import mock
++from unittest import mock
+
+ from nose.plugins.attrib import attr
+
+diff -aur boto-2.49.0.20190327/tests/integration/s3/test_multipart.py
boto-2.49.0.20190327.new/tests/integration/s3/test_multipart.py
+--- boto-2.49.0.20190327/tests/integration/s3/test_multipart.py
2019-03-27 02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/integration/s3/test_multipart.py
2022-11-12 17:57:07.306831428 +0100
+@@ -37,7 +37,7 @@
+ import time
+ from boto.compat import StringIO
+
+-import mock
++from unittest import mock
+
+ import boto
+ from boto.s3.connection import S3Connection
+diff -aur boto-2.49.0.20190327/tests/unit/auth/test_stsanon.py
boto-2.49.0.20190327.new/tests/unit/auth/test_stsanon.py
+--- boto-2.49.0.20190327/tests/unit/auth/test_stsanon.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/auth/test_stsanon.py 2022-11-12
17:45:37.652260517 +0100
+@@ -20,7 +20,7 @@
+ # IN THE SOFTWARE.
+ #
+ import copy
+-from mock import Mock
++from unittest.mock import Mock
+ from tests.unit import unittest
+
+ from boto.auth import STSAnonHandler
+diff -aur boto-2.49.0.20190327/tests/unit/cloudformation/test_connection.py
boto-2.49.0.20190327.new/tests/unit/cloudformation/test_connection.py
+--- boto-2.49.0.20190327/tests/unit/cloudformation/test_connection.py
2019-03-27 02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/cloudformation/test_connection.py
2022-11-12 17:45:37.655593923 +0100
+@@ -1,7 +1,7 @@
+ #!/usr/bin/env python
+ import unittest
+ from datetime import datetime
+-from mock import Mock
++from unittest.mock import Mock
+
+ from tests.unit import AWSMockServiceTestCase
+ from boto.cloudformation.connection import CloudFormationConnection
+diff -aur boto-2.49.0.20190327/tests/unit/cloudsearch/test_document.py
boto-2.49.0.20190327.new/tests/unit/cloudsearch/test_document.py
+--- boto-2.49.0.20190327/tests/unit/cloudsearch/test_document.py
2019-03-27 02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/cloudsearch/test_document.py
2022-11-12 17:45:37.655593923 +0100
+@@ -2,7 +2,7 @@
+
+ from tests.unit import unittest
+ from httpretty import HTTPretty
+-from mock import MagicMock
++from unittest.mock import MagicMock
+
+ import json
+
+diff -aur boto-2.49.0.20190327/tests/unit/cloudsearch2/test_document.py
boto-2.49.0.20190327.new/tests/unit/cloudsearch2/test_document.py
+--- boto-2.49.0.20190327/tests/unit/cloudsearch2/test_document.py
2019-03-27 02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/cloudsearch2/test_document.py
2022-11-12 17:45:37.655593923 +0100
+@@ -4,7 +4,7 @@
+
+ from tests.unit import unittest, AWSMockServiceTestCase
+ from httpretty import HTTPretty
+-from mock import MagicMock
++from unittest.mock import MagicMock
+
+ import json
+
+diff -aur
boto-2.49.0.20190327/tests/unit/cloudsearchdomain/test_cloudsearchdomain.py
boto-2.49.0.20190327.new/tests/unit/cloudsearchdomain/test_cloudsearchdomain.py
+---
boto-2.49.0.20190327/tests/unit/cloudsearchdomain/test_cloudsearchdomain.py
2019-03-27 02:07:03.000000000 +0100
++++
boto-2.49.0.20190327.new/tests/unit/cloudsearchdomain/test_cloudsearchdomain.py
2022-11-12 17:56:32.289449217 +0100
+@@ -1,6 +1,6 @@
+ #!/usr/bin env python
+ import json
+-import mock
++from unittest import mock
+ from tests.unit import AWSMockServiceTestCase
+ from boto.cloudsearch2.domain import Domain
+ from boto.cloudsearch2.layer1 import CloudSearchConnection
+diff -aur boto-2.49.0.20190327/tests/unit/dynamodb/test_layer2.py
boto-2.49.0.20190327.new/tests/unit/dynamodb/test_layer2.py
+--- boto-2.49.0.20190327/tests/unit/dynamodb/test_layer2.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/dynamodb/test_layer2.py
2022-11-12 17:45:37.658927332 +0100
+@@ -22,7 +22,7 @@
+ #
+
+ from tests.unit import unittest
+-from mock import Mock
++from unittest.mock import Mock
+
+ from boto.dynamodb.layer2 import Layer2
+ from boto.dynamodb.table import Table, Schema
+diff -aur boto-2.49.0.20190327/tests/unit/ec2/test_connection.py
boto-2.49.0.20190327.new/tests/unit/ec2/test_connection.py
+--- boto-2.49.0.20190327/tests/unit/ec2/test_connection.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/ec2/test_connection.py 2022-11-12
17:45:37.662260738 +0100
+@@ -1,6 +1,6 @@
+ #!/usr/bin/env python
+ from datetime import datetime, timedelta
+-from mock import MagicMock, Mock
++from unittest.mock import MagicMock, Mock
+ from tests.unit import unittest
+ from tests.unit import AWSMockServiceTestCase
+
+diff -aur
boto-2.49.0.20190327/tests/unit/ec2containerservice/test_connection.py
boto-2.49.0.20190327.new/tests/unit/ec2containerservice/test_connection.py
+--- boto-2.49.0.20190327/tests/unit/ec2containerservice/test_connection.py
2019-03-27 02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/ec2containerservice/test_connection.py
2022-11-12 17:45:37.662260738 +0100
+@@ -20,7 +20,7 @@
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
+ # IN THE SOFTWARE.
+ #
+-from mock import Mock
++from unittest.mock import Mock
+ from tests.unit import unittest
+
+ import boto.ec2containerservice
+diff -aur boto-2.49.0.20190327/tests/unit/glacier/test_layer2.py
boto-2.49.0.20190327.new/tests/unit/glacier/test_layer2.py
+--- boto-2.49.0.20190327/tests/unit/glacier/test_layer2.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/glacier/test_layer2.py 2022-11-12
17:45:37.668927553 +0100
+@@ -23,7 +23,7 @@
+
+ from tests.unit import unittest
+
+-from mock import call, Mock, patch, sentinel
++from unittest.mock import call, Mock, patch, sentinel
+
+ import codecs
+ from boto.glacier.layer1 import Layer1
+diff -aur boto-2.49.0.20190327/tests/unit/glacier/test_writer.py
boto-2.49.0.20190327.new/tests/unit/glacier/test_writer.py
+--- boto-2.49.0.20190327/tests/unit/glacier/test_writer.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/glacier/test_writer.py 2022-11-12
17:45:37.668927553 +0100
+@@ -24,7 +24,7 @@
+ from boto.compat import StringIO
+
+ from tests.unit import unittest
+-from mock import (
++from unittest.mock import (
+ call,
+ Mock,
+ sentinel,
+diff -aur boto-2.49.0.20190327/tests/unit/mws/test_connection.py
boto-2.49.0.20190327.new/tests/unit/mws/test_connection.py
+--- boto-2.49.0.20190327/tests/unit/mws/test_connection.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/mws/test_connection.py 2022-11-12
17:45:37.672260962 +0100
+@@ -29,7 +29,7 @@
+
+ from tests.unit import AWSMockServiceTestCase
+
+-from mock import MagicMock
++from unittest.mock import MagicMock
+
+
+ class TestMWSConnection(AWSMockServiceTestCase):
+diff -aur boto-2.49.0.20190327/tests/unit/s3/test_bucketlistresultset.py
boto-2.49.0.20190327.new/tests/unit/s3/test_bucketlistresultset.py
+--- boto-2.49.0.20190327/tests/unit/s3/test_bucketlistresultset.py
2019-03-27 02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/s3/test_bucketlistresultset.py
2022-11-12 17:45:37.675594369 +0100
+@@ -22,7 +22,7 @@
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
+ # IN THE SOFTWARE.
+
+-from mock import patch, Mock
++from unittest.mock import patch, Mock
+ import unittest
+
+ from boto.s3.bucket import ResultSet
+diff -aur boto-2.49.0.20190327/tests/unit/s3/test_bucket.py
boto-2.49.0.20190327.new/tests/unit/s3/test_bucket.py
+--- boto-2.49.0.20190327/tests/unit/s3/test_bucket.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/s3/test_bucket.py 2022-11-12
17:45:37.675594369 +0100
+@@ -1,5 +1,5 @@
+ # -*- coding: utf-8 -*-
+-from mock import patch
++from unittest.mock import patch
+ import xml.dom.minidom
+
+ from tests.unit import unittest
+diff -aur boto-2.49.0.20190327/tests/unit/sns/test_connection.py
boto-2.49.0.20190327.new/tests/unit/sns/test_connection.py
+--- boto-2.49.0.20190327/tests/unit/sns/test_connection.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/sns/test_connection.py 2022-11-12
17:45:37.678927776 +0100
+@@ -23,7 +23,7 @@
+ import json
+ from tests.unit import unittest
+ from tests.unit import AWSMockServiceTestCase
+-from mock import Mock
++from unittest.mock import Mock
+
+ from boto.sns.connection import SNSConnection
+
+diff -aur boto-2.49.0.20190327/tests/unit/sqs/test_queue.py
boto-2.49.0.20190327.new/tests/unit/sqs/test_queue.py
+--- boto-2.49.0.20190327/tests/unit/sqs/test_queue.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/sqs/test_queue.py 2022-11-12
17:45:37.678927776 +0100
+@@ -20,7 +20,7 @@
+ # IN THE SOFTWARE.
+ #
+ from tests.unit import unittest
+-from mock import Mock
++from unittest.mock import Mock
+
+ from boto.sqs.queue import Queue
+
+diff -aur boto-2.49.0.20190327/tests/unit/swf/test_layer2_actors.py
boto-2.49.0.20190327.new/tests/unit/swf/test_layer2_actors.py
+--- boto-2.49.0.20190327/tests/unit/swf/test_layer2_actors.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/swf/test_layer2_actors.py
2022-11-12 17:45:37.678927776 +0100
+@@ -1,7 +1,7 @@
+ import boto.swf.layer2
+ from boto.swf.layer2 import Decider, ActivityWorker
+ from tests.unit import unittest
+-from mock import Mock
++from unittest.mock import Mock
+
+
+ class TestActors(unittest.TestCase):
+diff -aur boto-2.49.0.20190327/tests/unit/swf/test_layer2_base.py
boto-2.49.0.20190327.new/tests/unit/swf/test_layer2_base.py
+--- boto-2.49.0.20190327/tests/unit/swf/test_layer2_base.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/swf/test_layer2_base.py
2022-11-12 17:45:37.678927776 +0100
+@@ -1,7 +1,7 @@
+ import boto.swf.layer2
+ from boto.swf.layer2 import SWFBase
+ from tests.unit import unittest
+-from mock import Mock
++from unittest.mock import Mock
+
+
+ MOCK_DOMAIN = 'Mock'
+diff -aur boto-2.49.0.20190327/tests/unit/swf/test_layer2_domain.py
boto-2.49.0.20190327.new/tests/unit/swf/test_layer2_domain.py
+--- boto-2.49.0.20190327/tests/unit/swf/test_layer2_domain.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/swf/test_layer2_domain.py
2022-11-12 17:45:37.678927776 +0100
+@@ -1,7 +1,7 @@
+ import boto.swf.layer2
+ from boto.swf.layer2 import Domain, ActivityType, WorkflowType,
WorkflowExecution
+ from tests.unit import unittest
+-from mock import Mock
++from unittest.mock import Mock
+
+
+ class TestDomain(unittest.TestCase):
+diff -aur boto-2.49.0.20190327/tests/unit/swf/test_layer2_types.py
boto-2.49.0.20190327.new/tests/unit/swf/test_layer2_types.py
+--- boto-2.49.0.20190327/tests/unit/swf/test_layer2_types.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/swf/test_layer2_types.py
2022-11-12 17:45:37.678927776 +0100
+@@ -1,7 +1,7 @@
+ import boto.swf.layer2
+ from boto.swf.layer2 import ActivityType, WorkflowType, WorkflowExecution
+ from tests.unit import unittest
+-from mock import Mock, ANY
++from unittest.mock import Mock, ANY
+
+
+ class TestTypes(unittest.TestCase):
+diff -aur boto-2.49.0.20190327/tests/unit/test_endpoints.py
boto-2.49.0.20190327.new/tests/unit/test_endpoints.py
+--- boto-2.49.0.20190327/tests/unit/test_endpoints.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/test_endpoints.py 2022-11-12
17:50:47.358958026 +0100
+@@ -10,7 +10,7 @@
+ # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF
+ # ANY KIND, either express or implied. See the License for the specific
+ # language governing permissions and limitations under the License.
+-import mock
++import unittest.mock as mock
+ import os
+ import json
+
+diff -aur boto-2.49.0.20190327/tests/unit/test_regioninfo.py
boto-2.49.0.20190327.new/tests/unit/test_regioninfo.py
+--- boto-2.49.0.20190327/tests/unit/test_regioninfo.py 2019-03-27
02:07:03.000000000 +0100
++++ boto-2.49.0.20190327.new/tests/unit/test_regioninfo.py 2022-11-12
17:50:51.855719636 +0100
+@@ -20,7 +20,7 @@
+ # IN THE SOFTWARE.
+ #
+ import os
+-import mock
++import unittest.mock as mock
+
+ import boto
+ from boto.pyami.config import Config