>>> py3-tempita: Building community/py3-tempita 0.5.2-r13 (using abuild 3.12.0-r5) started Fri, 12 Apr 2024 16:29:18 +0000 >>> py3-tempita: Checking sanity of /home/buildozer/aports/community/py3-tempita/APKBUILD... >>> py3-tempita: Analyzing dependencies... >>> py3-tempita: Installing for build: build-base python3 py3-setuptools (1/19) Installing libbz2 (1.0.8-r6) (2/19) Installing libffi (3.4.6-r0) (3/19) Installing gdbm (1.23-r1) (4/19) Installing xz-libs (5.6.1-r3) (5/19) Installing mpdecimal (4.0.0-r0) (6/19) Installing libpanelw (6.4_p20240330-r0) (7/19) Installing readline (8.2.10-r0) (8/19) Installing sqlite-libs (3.45.2-r0) (9/19) Installing python3 (3.12.2-r1) (10/19) Installing python3-pycache-pyc0 (3.12.2-r1) (11/19) Installing pyc (3.12.2-r1) (12/19) Installing python3-pyc (3.12.2-r1) (13/19) Installing py3-parsing (3.1.2-r1) (14/19) Installing py3-parsing-pyc (3.1.2-r1) (15/19) Installing py3-packaging (24.0-r1) (16/19) Installing py3-packaging-pyc (24.0-r1) (17/19) Installing py3-setuptools (69.2.0-r1) (18/19) Installing py3-setuptools-pyc (69.2.0-r1) (19/19) Installing .makedepends-py3-tempita (20240412.162919) Executing busybox-1.36.1-r25.trigger OK: 360 MiB in 122 packages >>> py3-tempita: Cleaning up srcdir >>> py3-tempita: Cleaning up pkgdir >>> py3-tempita: Cleaning up tmpdir >>> py3-tempita: Fetching https://distfiles.alpinelinux.org/distfiles/edge/Tempita-0.5.2.tar.gz Connecting to distfiles.alpinelinux.org (172.105.82.32:443) saving to '/var/cache/distfiles/Tempita-0.5.2.tar.gz.part' Tempita-0.5.2.tar.gz 100% |********************************| 12648 0:00:00 ETA '/var/cache/distfiles/Tempita-0.5.2.tar.gz.part' saved >>> py3-tempita: Fetching https://distfiles.alpinelinux.org/distfiles/edge/Tempita-0.5.2.tar.gz >>> py3-tempita: Checking sha512sums... Tempita-0.5.2.tar.gz: OK setuptools59.patch: OK >>> py3-tempita: Unpacking /var/cache/distfiles/Tempita-0.5.2.tar.gz... >>> py3-tempita: setuptools59.patch patching file setup.py /usr/bin/2to3:3: DeprecationWarning: lib2to3 package is deprecated and may not be able to parse Python 3.10+ from lib2to3.main import main RefactoringTool: Skipping optional fixer: buffer RefactoringTool: Skipping optional fixer: idioms RefactoringTool: Skipping optional fixer: set_literal RefactoringTool: Skipping optional fixer: ws_comma RefactoringTool: No changes to ./setup.py RefactoringTool: Refactored ./tempita/__init__.py RefactoringTool: No changes to ./tempita/_looper.py RefactoringTool: Refactored ./tempita/compat3.py RefactoringTool: Files that were modified: RefactoringTool: ./setup.py RefactoringTool: ./tempita/__init__.py RefactoringTool: ./tempita/_looper.py RefactoringTool: ./tempita/compat3.py RefactoringTool: Warnings/messages while refactoring: RefactoringTool: ### In file ./tempita/__init__.py ### RefactoringTool: Line 40: Calls to builtin next() possibly shadowed by global binding RefactoringTool: ### In file ./tempita/compat3.py ### RefactoringTool: Line 23: Calls to builtin next() possibly shadowed by global binding --- ./tempita/__init__.py (original) +++ ./tempita/__init__.py (refactored) @@ -32,10 +32,10 @@ import re import sys import cgi -from urllib import quote as url_quote +from urllib.parse import quote as url_quote import os import tokenize -from cStringIO import StringIO +from io import StringIO from tempita._looper import looper from tempita.compat3 import bytes, basestring_, next, is_unicode, coerce_text @@ -101,7 +101,7 @@ delimiters = (self.default_namespace['start_braces'], self.default_namespace['end_braces']) else: - assert len(delimiters) == 2 and all([isinstance(delimeter, basestring) + assert len(delimiters) == 2 and all([isinstance(delimeter, str) for delimeter in delimiters]) self.default_namespace = self.__class__.default_namespace.copy() self.default_namespace['start_braces'] = delimiters[0] @@ -196,7 +196,7 @@ position=None, name=self.name) templ = self.get_template(inherit_template, self) self_ = TemplateObject(self.name) - for name, value in defs.iteritems(): + for name, value in defs.items(): setattr(self_, name, value) self_.body = body ns = ns.copy() @@ -292,7 +292,7 @@ try: try: value = eval(code, self.default_namespace, ns) - except SyntaxError, e: + except SyntaxError as e: raise SyntaxError( 'invalid syntax in expression: %s' % code) return value @@ -304,12 +304,12 @@ else: arg0 = coerce_text(e) e.args = (self._add_line_info(arg0, pos),) - raise exc_info[0], e, exc_info[2] + raise exc_info[0](e).with_traceback(exc_info[2]) def _exec(self, code, ns, pos): __traceback_hide__ = True try: - exec code in self.default_namespace, ns + exec(code, self.default_namespace, ns) except: exc_info = sys.exc_info() e = exc_info[1] @@ -317,7 +317,7 @@ e.args = (self._add_line_info(e.args[0], pos),) else: e.args = (self._add_line_info(None, pos),) - raise exc_info[0], e, exc_info[2] + raise exc_info[0](e).with_traceback(exc_info[2]) def _repr(self, value, pos): __traceback_hide__ = True @@ -326,7 +326,7 @@ return '' if self._unicode: try: - value = unicode(value) + value = str(value) except UnicodeDecodeError: value = bytes(value) else: @@ -339,7 +339,7 @@ exc_info = sys.exc_info() e = exc_info[1] e.args = (self._add_line_info(e.args[0], pos),) - raise exc_info[0], e, exc_info[2] + raise exc_info[0](e).with_traceback(exc_info[2]) else: if self._unicode and isinstance(value, bytes): if not self.default_encoding: @@ -348,7 +348,7 @@ '(no default_encoding provided)' % value) try: value = value.decode(self.default_encoding) - except UnicodeDecodeError, e: + except UnicodeDecodeError as e: raise UnicodeDecodeError( e.encoding, e.object, @@ -385,7 +385,7 @@ class bunch(dict): def __init__(self, **kw): - for name, value in kw.iteritems(): + for name, value in kw.items(): setattr(self, name, value) def __setattr__(self, name, value): @@ -408,7 +408,7 @@ def __repr__(self): items = [ - (k, v) for k, v in self.iteritems()] + (k, v) for k, v in self.items()] items.sort() return '<%s %s>' % ( self.__class__.__name__, @@ -461,7 +461,7 @@ def attr(**kw): - kw = list(kw.iteritems()) + kw = list(kw.items()) kw.sort() parts = [] for name, value in kw: @@ -543,7 +543,7 @@ values = {} sig_args, var_args, var_kw, defaults = self._func_signature extra_kw = {} - for name, value in kw.iteritems(): + for name, value in kw.items(): if not var_kw and name not in sig_args: raise TypeError( 'Unexpected argument %s' % name) @@ -566,7 +566,7 @@ raise TypeError( 'Extra position arguments: %s' % ', '.join(repr(v) for v in args)) - for name, value_expr in defaults.iteritems(): + for name, value_expr in defaults.items(): if name not in values: values[name] = self._template._eval( value_expr, self._ns, self._pos) @@ -612,7 +612,7 @@ return 'Empty' def __unicode__(self): - return u'' + return '' def __iter__(self): return iter(()) @@ -1156,7 +1156,7 @@ vars.update(os.environ) for value in args: if '=' not in value: - print('Bad argument: %r' % value) + print(('Bad argument: %r' % value)) sys.exit(2) name, value = value.split('=', 1) if name.startswith('py:'): --- ./tempita/compat3.py (original) +++ ./tempita/compat3.py (refactored) @@ -4,7 +4,7 @@ if sys.version < "3": b = bytes = str - basestring_ = basestring + basestring_ = str else: def b(s): @@ -18,14 +18,14 @@ if sys.version < "3": def next(obj): - return obj.next() + return obj.__next__() else: next = next if sys.version < "3": def is_unicode(obj): - return isinstance(obj, unicode) + return isinstance(obj, str) else: def is_unicode(obj): @@ -39,7 +39,7 @@ else: attr = '__str__' if hasattr(v, attr): - return unicode(v) + return str(v) else: return bytes(v) return v running build running build_py creating build creating build/lib creating build/lib/tempita copying tempita/__init__.py -> build/lib/tempita copying tempita/_looper.py -> build/lib/tempita copying tempita/__main__.py -> build/lib/tempita copying tempita/compat3.py -> build/lib/tempita running egg_info writing Tempita.egg-info/PKG-INFO writing dependency_links to Tempita.egg-info/dependency_links.txt writing top-level names to Tempita.egg-info/top_level.txt reading manifest file 'Tempita.egg-info/SOURCES.txt' writing manifest file 'Tempita.egg-info/SOURCES.txt' >>> py3-tempita: Entering fakeroot... running install /usr/lib/python3.12/site-packages/setuptools/_distutils/cmd.py:66: SetuptoolsDeprecationWarning: setup.py install is deprecated. !! ******************************************************************************** Please avoid running ``setup.py`` directly. Instead, use pypa/build, pypa/installer or other standards-based tools. See https://blog.ganssle.io/articles/2021/10/setup-py-deprecated.html for details. ******************************************************************************** !! self.initialize_options() running install_lib creating /home/buildozer/aports/community/py3-tempita/pkg creating /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita creating /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr creating /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib creating /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12 creating /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12/site-packages creating /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12/site-packages/tempita copying build/lib/tempita/__init__.py -> /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12/site-packages/tempita copying build/lib/tempita/_looper.py -> /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12/site-packages/tempita copying build/lib/tempita/__main__.py -> /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12/site-packages/tempita copying build/lib/tempita/compat3.py -> /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12/site-packages/tempita byte-compiling /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12/site-packages/tempita/__init__.py to __init__.cpython-312.pyc byte-compiling /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12/site-packages/tempita/_looper.py to _looper.cpython-312.pyc byte-compiling /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12/site-packages/tempita/__main__.py to __main__.cpython-312.pyc byte-compiling /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12/site-packages/tempita/compat3.py to compat3.cpython-312.pyc running install_egg_info running egg_info writing Tempita.egg-info/PKG-INFO writing dependency_links to Tempita.egg-info/dependency_links.txt writing top-level names to Tempita.egg-info/top_level.txt reading manifest file 'Tempita.egg-info/SOURCES.txt' writing manifest file 'Tempita.egg-info/SOURCES.txt' Copying Tempita.egg-info to /home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12/site-packages/Tempita-0.5.2-py3.12.egg-info running install_scripts >>> py3-tempita-pyc*: Running split function pyc... '/home/buildozer/aports/community/py3-tempita/pkg/py3-tempita/usr/lib/python3.12/site-packages/tempita/__pycache__' -> '/home/buildozer/aports/community/py3-tempita/pkg/py3-tempita-pyc/usr/lib/python3.12/site-packages/tempita/__pycache__' >>> py3-tempita-pyc*: Preparing subpackage py3-tempita-pyc... >>> py3-tempita-pyc*: Running postcheck for py3-tempita-pyc >>> py3-tempita*: Running postcheck for py3-tempita >>> py3-tempita*: Preparing package py3-tempita... >>> py3-tempita-pyc*: Tracing dependencies... python3 python3~3.12 >>> py3-tempita-pyc*: Package size: 96.0 KB >>> py3-tempita-pyc*: Compressing data... >>> py3-tempita-pyc*: Create checksum... >>> py3-tempita-pyc*: Create py3-tempita-pyc-0.5.2-r13.apk >>> py3-tempita*: Tracing dependencies... python3 python3~3.12 >>> py3-tempita*: Package size: 104.0 KB >>> py3-tempita*: Compressing data... >>> py3-tempita*: Create checksum... >>> py3-tempita*: Create py3-tempita-0.5.2-r13.apk >>> py3-tempita: Build complete at Fri, 12 Apr 2024 16:29:21 +0000 elapsed time 0h 0m 3s >>> py3-tempita: Cleaning up srcdir >>> py3-tempita: Cleaning up pkgdir >>> py3-tempita: Uninstalling dependencies... (1/19) Purging .makedepends-py3-tempita (20240412.162919) (2/19) Purging py3-setuptools-pyc (69.2.0-r1) (3/19) Purging py3-setuptools (69.2.0-r1) (4/19) Purging py3-packaging-pyc (24.0-r1) (5/19) Purging py3-packaging (24.0-r1) (6/19) Purging py3-parsing-pyc (3.1.2-r1) (7/19) Purging py3-parsing (3.1.2-r1) (8/19) Purging python3-pyc (3.12.2-r1) (9/19) Purging python3-pycache-pyc0 (3.12.2-r1) (10/19) Purging pyc (3.12.2-r1) (11/19) Purging python3 (3.12.2-r1) (12/19) Purging gdbm (1.23-r1) (13/19) Purging libbz2 (1.0.8-r6) (14/19) Purging libffi (3.4.6-r0) (15/19) Purging libpanelw (6.4_p20240330-r0) (16/19) Purging mpdecimal (4.0.0-r0) (17/19) Purging readline (8.2.10-r0) (18/19) Purging sqlite-libs (3.45.2-r0) (19/19) Purging xz-libs (5.6.1-r3) Executing busybox-1.36.1-r25.trigger OK: 315 MiB in 103 packages >>> py3-tempita: Updating the community/armhf repository index... >>> py3-tempita: Signing the index...