git: d72d78752c42 - main - sysutils/py-mitogen: update to v0.3.19

From: Dave Cottlehuber <dch_at_FreeBSD.org>
Date: Wed, 04 Dec 2024 16:43:50 UTC
The branch main has been updated by dch:

URL: https://cgit.FreeBSD.org/ports/commit/?id=d72d78752c42732a476fbf543062fd8e2b398657

commit d72d78752c42732a476fbf543062fd8e2b398657
Author:     Dave Cottlehuber <dch@FreeBSD.org>
AuthorDate: 2024-12-03 21:01:56 +0000
Commit:     Dave Cottlehuber <dch@FreeBSD.org>
CommitDate: 2024-12-04 16:43:26 +0000

    sysutils/py-mitogen: update to v0.3.19
    
    Reported by:    portscout
    Sponsored by:   SkunkWerks, GmbH
---
 sysutils/py-mitogen/Makefile                       |   2 +-
 sysutils/py-mitogen/distinfo                       |   6 +-
 sysutils/py-mitogen/files/patch-2to3               | 169 ---------------------
 .../files/patch-ansible__mitogen_loaders.py        |  11 --
 4 files changed, 4 insertions(+), 184 deletions(-)

diff --git a/sysutils/py-mitogen/Makefile b/sysutils/py-mitogen/Makefile
index e3d2e6ba9ba3..040dd284ac11 100644
--- a/sysutils/py-mitogen/Makefile
+++ b/sysutils/py-mitogen/Makefile
@@ -1,5 +1,5 @@
 PORTNAME=	mitogen
-DISTVERSION=	0.3.3
+DISTVERSION=	0.3.19
 CATEGORIES=	sysutils python
 MASTER_SITES=	PYPI
 PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
diff --git a/sysutils/py-mitogen/distinfo b/sysutils/py-mitogen/distinfo
index bab25fa9a6d6..fb8f55622490 100644
--- a/sysutils/py-mitogen/distinfo
+++ b/sysutils/py-mitogen/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1659648435
-SHA256 (mitogen-0.3.3.tar.gz) = db9dbc1ca8acb59f8f70c25a0fbdf11698b1a8b8355f39a8c540e0874496fb34
-SIZE (mitogen-0.3.3.tar.gz) = 219703
+TIMESTAMP = 1733174109
+SHA256 (mitogen-0.3.19.tar.gz) = 04e2f5b2e33af034c25a770fa5c6045e383ef3835e4f0c68692424c021f94a33
+SIZE (mitogen-0.3.19.tar.gz) = 225263
diff --git a/sysutils/py-mitogen/files/patch-2to3 b/sysutils/py-mitogen/files/patch-2to3
deleted file mode 100644
index 5a2522d2a281..000000000000
--- a/sysutils/py-mitogen/files/patch-2to3
+++ /dev/null
@@ -1,169 +0,0 @@
---- ansible_mitogen/compat/simplejson/decoder.py.orig	2019-11-02 17:59:13 UTC
-+++ ansible_mitogen/compat/simplejson/decoder.py
-@@ -56,8 +56,8 @@ _CONSTANTS = {
- 
- STRINGCHUNK = re.compile(r'(.*?)(["\\\x00-\x1f])', FLAGS)
- BACKSLASH = {
--    '"': u'"', '\\': u'\\', '/': u'/',
--    'b': u'\b', 'f': u'\f', 'n': u'\n', 'r': u'\r', 't': u'\t',
-+    '"': '"', '\\': '\\', '/': '/',
-+    'b': '\b', 'f': '\f', 'n': '\n', 'r': '\r', 't': '\t',
- }
- 
- DEFAULT_ENCODING = "utf-8"
-@@ -85,8 +85,8 @@ def py_scanstring(s, end, encoding=None, strict=True, 
-         content, terminator = chunk.groups()
-         # Content is contains zero or more unescaped string characters
-         if content:
--            if not isinstance(content, unicode):
--                content = unicode(content, encoding)
-+            if not isinstance(content, str):
-+                content = str(content, encoding)
-             _append(content)
-         # Terminator is the end of string, a literal control character,
-         # or a backslash denoting that an escape sequence follows
-@@ -132,11 +132,11 @@ def py_scanstring(s, end, encoding=None, strict=True, 
-                 uni2 = int(esc2, 16)
-                 uni = 0x10000 + (((uni - 0xd800) << 10) | (uni2 - 0xdc00))
-                 next_end += 6
--            char = unichr(uni)
-+            char = chr(uni)
-             end = next_end
-         # Append the unescaped character
-         _append(char)
--    return u''.join(chunks), end
-+    return ''.join(chunks), end
- 
- 
- # Use speedup if available
-@@ -145,7 +145,8 @@ scanstring = c_scanstring or py_scanstring
- WHITESPACE = re.compile(r'[ \t\n\r]*', FLAGS)
- WHITESPACE_STR = ' \t\n\r'
- 
--def JSONObject((s, end), encoding, strict, scan_once, object_hook, _w=WHITESPACE.match, _ws=WHITESPACE_STR):
-+def JSONObject(xxx_todo_changeme, encoding, strict, scan_once, object_hook, _w=WHITESPACE.match, _ws=WHITESPACE_STR):
-+    (s, end) = xxx_todo_changeme
-     pairs = {}
-     # Use a slice to prevent IndexError from being raised, the following
-     # check will raise a more specific ValueError if the string is empty
-@@ -220,7 +221,8 @@ def JSONObject((s, end), encoding, strict, scan_once, 
-         pairs = object_hook(pairs)
-     return pairs, end
- 
--def JSONArray((s, end), scan_once, _w=WHITESPACE.match, _ws=WHITESPACE_STR):
-+def JSONArray(xxx_todo_changeme1, scan_once, _w=WHITESPACE.match, _ws=WHITESPACE_STR):
-+    (s, end) = xxx_todo_changeme1
-     values = []
-     nextchar = s[end:end + 1]
-     if nextchar in _ws:
---- ansible_mitogen/compat/simplejson/encoder.py.orig	2019-11-02 17:59:13 UTC
-+++ ansible_mitogen/compat/simplejson/encoder.py
-@@ -184,7 +184,7 @@ class JSONEncoder(object):
- 
-         """
-         # This is for extremely simple cases and benchmarks.
--        if isinstance(o, basestring):
-+        if isinstance(o, str):
-             if isinstance(o, str):
-                 _encoding = self.encoding
-                 if (_encoding is not None
-@@ -261,18 +261,15 @@ class JSONEncoder(object):
- 
- def _make_iterencode(markers, _default, _encoder, _indent, _floatstr, _key_separator, _item_separator, _sort_keys, _skipkeys, _one_shot,
-         ## HACK: hand-optimized bytecode; turn globals into locals
--        False=False,
--        True=True,
-         ValueError=ValueError,
--        basestring=basestring,
-+        str=str,
-         dict=dict,
-         float=float,
-         id=id,
-         int=int,
-         isinstance=isinstance,
-         list=list,
--        long=long,
--        str=str,
-+        long=int,
-         tuple=tuple,
-     ):
- 
-@@ -300,7 +297,7 @@ def _make_iterencode(markers, _default, _encoder, _ind
-                 first = False
-             else:
-                 buf = separator
--            if isinstance(value, basestring):
-+            if isinstance(value, str):
-                 yield buf + _encoder(value)
-             elif value is None:
-                 yield buf + 'null'
-@@ -308,7 +305,7 @@ def _make_iterencode(markers, _default, _encoder, _ind
-                 yield buf + 'true'
-             elif value is False:
-                 yield buf + 'false'
--            elif isinstance(value, (int, long)):
-+            elif isinstance(value, int):
-                 yield buf + str(value)
-             elif isinstance(value, float):
-                 yield buf + _floatstr(value)
-@@ -349,12 +346,12 @@ def _make_iterencode(markers, _default, _encoder, _ind
-             item_separator = _item_separator
-         first = True
-         if _sort_keys:
--            items = dct.items()
-+            items = list(dct.items())
-             items.sort(key=lambda kv: kv[0])
-         else:
--            items = dct.iteritems()
-+            items = iter(dct.items())
-         for key, value in items:
--            if isinstance(key, basestring):
-+            if isinstance(key, str):
-                 pass
-             # JavaScript is weakly typed for these, so it makes sense to
-             # also allow them.  Many encoders seem to do something like this.
-@@ -366,7 +363,7 @@ def _make_iterencode(markers, _default, _encoder, _ind
-                 key = 'false'
-             elif key is None:
-                 key = 'null'
--            elif isinstance(key, (int, long)):
-+            elif isinstance(key, int):
-                 key = str(key)
-             elif _skipkeys:
-                 continue
-@@ -378,7 +375,7 @@ def _make_iterencode(markers, _default, _encoder, _ind
-                 yield item_separator
-             yield _encoder(key)
-             yield _key_separator
--            if isinstance(value, basestring):
-+            if isinstance(value, str):
-                 yield _encoder(value)
-             elif value is None:
-                 yield 'null'
-@@ -386,7 +383,7 @@ def _make_iterencode(markers, _default, _encoder, _ind
-                 yield 'true'
-             elif value is False:
-                 yield 'false'
--            elif isinstance(value, (int, long)):
-+            elif isinstance(value, int):
-                 yield str(value)
-             elif isinstance(value, float):
-                 yield _floatstr(value)
-@@ -407,7 +404,7 @@ def _make_iterencode(markers, _default, _encoder, _ind
-             del markers[markerid]
- 
-     def _iterencode(o, _current_indent_level):
--        if isinstance(o, basestring):
-+        if isinstance(o, str):
-             yield _encoder(o)
-         elif o is None:
-             yield 'null'
-@@ -415,7 +412,7 @@ def _make_iterencode(markers, _default, _encoder, _ind
-             yield 'true'
-         elif o is False:
-             yield 'false'
--        elif isinstance(o, (int, long)):
-+        elif isinstance(o, int):
-             yield str(o)
-         elif isinstance(o, float):
-             yield _floatstr(o)
diff --git a/sysutils/py-mitogen/files/patch-ansible__mitogen_loaders.py b/sysutils/py-mitogen/files/patch-ansible__mitogen_loaders.py
deleted file mode 100644
index 61cc5690f103..000000000000
--- a/sysutils/py-mitogen/files/patch-ansible__mitogen_loaders.py
+++ /dev/null
@@ -1,11 +0,0 @@
---- ansible_mitogen/loaders.py.orig	2022-08-09 10:30:15 UTC
-+++ ansible_mitogen/loaders.py
-@@ -48,7 +48,7 @@ ANSIBLE_VERSION_MIN = (2, 10)
- 
- 
- ANSIBLE_VERSION_MIN = (2, 10)
--ANSIBLE_VERSION_MAX = (2, 12)
-+ANSIBLE_VERSION_MAX = (2, 13)
- 
- NEW_VERSION_MSG = (
-     "Your Ansible version (%s) is too recent. The most recent version\n"