>>> py3-pylink-square: Building community/py3-pylink-square 1.2.0-r1 (using abuild 3.12.0-r5) started Thu, 28 Mar 2024 12:01:35 +0000 >>> py3-pylink-square: Checking sanity of /home/buildozer/aports/community/py3-pylink-square/APKBUILD... >>> py3-pylink-square: Analyzing dependencies... >>> py3-pylink-square: Installing for build: build-base py3-psutil py3-six py3-gpep517 py3-installer py3-setuptools py3-wheel py3-mock py3-pytest (1/39) Installing libbz2 (1.0.8-r6) (2/39) Installing libffi (3.4.6-r0) (3/39) Installing gdbm (1.23-r1) (4/39) Installing xz-libs (5.6.1-r1) (5/39) Installing mpdecimal (4.0.0-r0) (6/39) Installing libpanelw (6.4_p20240309-r0) (7/39) Installing readline (8.2.10-r0) (8/39) Installing sqlite-libs (3.45.2-r0) (9/39) Installing python3 (3.11.8-r0) (10/39) Installing python3-pycache-pyc0 (3.11.8-r0) (11/39) Installing pyc (3.11.8-r0) (12/39) Installing py3-psutil-pyc (5.9.8-r0) (13/39) Installing python3-pyc (3.11.8-r0) (14/39) Installing py3-psutil (5.9.8-r0) (15/39) Installing py3-six (1.16.0-r8) (16/39) Installing py3-six-pyc (1.16.0-r8) (17/39) Installing py3-installer (0.7.0-r1) (18/39) Installing py3-installer-pyc (0.7.0-r1) (19/39) Installing py3-gpep517 (15-r1) (20/39) Installing py3-gpep517-pyc (15-r1) (21/39) Installing py3-parsing (3.1.2-r0) (22/39) Installing py3-parsing-pyc (3.1.2-r0) (23/39) Installing py3-packaging (24.0-r0) (24/39) Installing py3-packaging-pyc (24.0-r0) (25/39) Installing py3-setuptools (69.2.0-r0) (26/39) Installing py3-setuptools-pyc (69.2.0-r0) (27/39) Installing py3-wheel (0.42.0-r0) (28/39) Installing py3-wheel-pyc (0.42.0-r0) (29/39) Installing py3-mock (5.1.0-r1) (30/39) Installing py3-mock-pyc (5.1.0-r1) (31/39) Installing py3-iniconfig (2.0.0-r0) (32/39) Installing py3-iniconfig-pyc (2.0.0-r0) (33/39) Installing py3-pluggy (1.4.0-r0) (34/39) Installing py3-pluggy-pyc (1.4.0-r0) (35/39) Installing py3-py (1.11.0-r2) (36/39) Installing py3-py-pyc (1.11.0-r2) (37/39) Installing py3-pytest (8.1.1-r0) (38/39) Installing py3-pytest-pyc (8.1.1-r0) (39/39) Installing .makedepends-py3-pylink-square (20240328.120136) Executing busybox-1.36.1-r24.trigger OK: 404 MiB in 146 packages >>> py3-pylink-square: Cleaning up srcdir >>> py3-pylink-square: Cleaning up pkgdir >>> py3-pylink-square: Cleaning up tmpdir >>> py3-pylink-square: Fetching https://distfiles.alpinelinux.org/distfiles/edge//pylink-square-1.2.0.tar.gz >>> py3-pylink-square: Fetching https://distfiles.alpinelinux.org/distfiles/edge//pylink-square-1.2.0.tar.gz >>> py3-pylink-square: Checking sha512sums... pylink-square-1.2.0.tar.gz: OK assertEquals.patch: OK >>> py3-pylink-square: Unpacking /var/cache/distfiles/edge/pylink-square-1.2.0.tar.gz... >>> py3-pylink-square: assertEquals.patch patching file tests/unit/test_library.py 2024-03-28 12:01:37,126 gpep517 INFO Building wheel via backend setuptools.build_meta:__legacy__ /usr/lib/python3.11/site-packages/setuptools/dist.py:476: SetuptoolsDeprecationWarning: Invalid dash-separated options !! ******************************************************************************** Usage of dash-separated 'description-file' will not be supported in future versions. Please use the underscore name 'description_file' instead. By 2024-Sep-26, you need to update your project and remove deprecated calls or your builds will no longer be supported. See https://setuptools.pypa.io/en/latest/userguide/declarative_config.html for details. ******************************************************************************** !! opt = self.warn_dash_deprecation(opt, section) 2024-03-28 12:01:37,199 root INFO running bdist_wheel 2024-03-28 12:01:37,209 root INFO running build 2024-03-28 12:01:37,209 root INFO running build_py 2024-03-28 12:01:37,211 root INFO creating build 2024-03-28 12:01:37,211 root INFO creating build/lib 2024-03-28 12:01:37,211 root INFO creating build/lib/pylink 2024-03-28 12:01:37,211 root INFO copying pylink/jlock.py -> build/lib/pylink 2024-03-28 12:01:37,211 root INFO copying pylink/structs.py -> build/lib/pylink 2024-03-28 12:01:37,211 root INFO copying pylink/__init__.py -> build/lib/pylink 2024-03-28 12:01:37,212 root INFO copying pylink/registers.py -> build/lib/pylink 2024-03-28 12:01:37,212 root INFO copying pylink/errors.py -> build/lib/pylink 2024-03-28 12:01:37,212 root INFO copying pylink/__main__.py -> build/lib/pylink 2024-03-28 12:01:37,212 root INFO copying pylink/library.py -> build/lib/pylink 2024-03-28 12:01:37,212 root INFO copying pylink/decorators.py -> build/lib/pylink 2024-03-28 12:01:37,212 root INFO copying pylink/jlink.py -> build/lib/pylink 2024-03-28 12:01:37,213 root INFO copying pylink/util.py -> build/lib/pylink 2024-03-28 12:01:37,213 root INFO copying pylink/threads.py -> build/lib/pylink 2024-03-28 12:01:37,213 root INFO copying pylink/enums.py -> build/lib/pylink 2024-03-28 12:01:37,214 root INFO copying pylink/binpacker.py -> build/lib/pylink 2024-03-28 12:01:37,214 root INFO creating build/lib/pylink/protocols 2024-03-28 12:01:37,214 root INFO copying pylink/protocols/__init__.py -> build/lib/pylink/protocols 2024-03-28 12:01:37,214 root INFO copying pylink/protocols/swd.py -> build/lib/pylink/protocols 2024-03-28 12:01:37,214 root INFO creating build/lib/pylink/unlockers 2024-03-28 12:01:37,214 root INFO copying pylink/unlockers/__init__.py -> build/lib/pylink/unlockers 2024-03-28 12:01:37,214 root INFO copying pylink/unlockers/unlock_kinetis.py -> build/lib/pylink/unlockers 2024-03-28 12:01:37,215 root INFO running build_scripts 2024-03-28 12:01:37,215 root INFO creating build/scripts-3.11 2024-03-28 12:01:37,215 root INFO copying and adjusting examples/pylink-rtt -> build/scripts-3.11 2024-03-28 12:01:37,215 root INFO copying and adjusting examples/pylink-swv -> build/scripts-3.11 2024-03-28 12:01:37,215 root INFO changing mode of build/scripts-3.11/pylink-rtt from 644 to 755 2024-03-28 12:01:37,215 root INFO changing mode of build/scripts-3.11/pylink-swv from 644 to 755 2024-03-28 12:01:37,218 wheel INFO installing to build/bdist.linux-s390x/wheel 2024-03-28 12:01:37,218 root INFO running install 2024-03-28 12:01:37,224 root INFO running install_lib 2024-03-28 12:01:37,225 root INFO creating build/bdist.linux-s390x 2024-03-28 12:01:37,225 root INFO creating build/bdist.linux-s390x/wheel 2024-03-28 12:01:37,225 root INFO creating build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,225 root INFO copying build/lib/pylink/jlock.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,225 root INFO copying build/lib/pylink/structs.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,225 root INFO copying build/lib/pylink/__init__.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,226 root INFO copying build/lib/pylink/registers.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,226 root INFO copying build/lib/pylink/errors.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,226 root INFO copying build/lib/pylink/__main__.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,226 root INFO copying build/lib/pylink/library.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,226 root INFO copying build/lib/pylink/decorators.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,226 root INFO copying build/lib/pylink/jlink.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,227 root INFO copying build/lib/pylink/util.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,227 root INFO creating build/bdist.linux-s390x/wheel/pylink/unlockers 2024-03-28 12:01:37,227 root INFO copying build/lib/pylink/unlockers/__init__.py -> build/bdist.linux-s390x/wheel/pylink/unlockers 2024-03-28 12:01:37,227 root INFO copying build/lib/pylink/unlockers/unlock_kinetis.py -> build/bdist.linux-s390x/wheel/pylink/unlockers 2024-03-28 12:01:37,227 root INFO creating build/bdist.linux-s390x/wheel/pylink/protocols 2024-03-28 12:01:37,227 root INFO copying build/lib/pylink/protocols/__init__.py -> build/bdist.linux-s390x/wheel/pylink/protocols 2024-03-28 12:01:37,227 root INFO copying build/lib/pylink/protocols/swd.py -> build/bdist.linux-s390x/wheel/pylink/protocols 2024-03-28 12:01:37,228 root INFO copying build/lib/pylink/threads.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,228 root INFO copying build/lib/pylink/enums.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,228 root INFO copying build/lib/pylink/binpacker.py -> build/bdist.linux-s390x/wheel/pylink 2024-03-28 12:01:37,228 root INFO running install_egg_info 2024-03-28 12:01:37,230 root INFO running egg_info 2024-03-28 12:01:37,231 root INFO writing pylink_square.egg-info/PKG-INFO 2024-03-28 12:01:37,232 root INFO writing dependency_links to pylink_square.egg-info/dependency_links.txt 2024-03-28 12:01:37,232 root INFO writing entry points to pylink_square.egg-info/entry_points.txt 2024-03-28 12:01:37,232 root INFO writing requirements to pylink_square.egg-info/requires.txt 2024-03-28 12:01:37,232 root INFO writing top-level names to pylink_square.egg-info/top_level.txt 2024-03-28 12:01:37,233 root INFO reading manifest file 'pylink_square.egg-info/SOURCES.txt' 2024-03-28 12:01:37,234 root INFO reading manifest template 'MANIFEST.in' 2024-03-28 12:01:37,244 root WARNING warning: no previously-included files matching '*.pyc' found anywhere in distribution 2024-03-28 12:01:37,244 root WARNING warning: no previously-included files matching '*.o' found anywhere in distribution 2024-03-28 12:01:37,244 root WARNING warning: no previously-included files matching '*.bin' found anywhere in distribution 2024-03-28 12:01:37,245 root WARNING warning: no previously-included files matching '*.elf' found anywhere in distribution 2024-03-28 12:01:37,245 root INFO adding license file 'LICENSE.md' 2024-03-28 12:01:37,246 root INFO writing manifest file 'pylink_square.egg-info/SOURCES.txt' 2024-03-28 12:01:37,246 root INFO Copying pylink_square.egg-info to build/bdist.linux-s390x/wheel/pylink_square-1.2.0-py3.11.egg-info 2024-03-28 12:01:37,246 root INFO running install_scripts 2024-03-28 12:01:37,246 root INFO creating build/bdist.linux-s390x/wheel/pylink_square-1.2.0.data 2024-03-28 12:01:37,246 root INFO creating build/bdist.linux-s390x/wheel/pylink_square-1.2.0.data/scripts 2024-03-28 12:01:37,247 root INFO copying build/scripts-3.11/pylink-rtt -> build/bdist.linux-s390x/wheel/pylink_square-1.2.0.data/scripts 2024-03-28 12:01:37,247 root INFO copying build/scripts-3.11/pylink-swv -> build/bdist.linux-s390x/wheel/pylink_square-1.2.0.data/scripts 2024-03-28 12:01:37,247 root INFO changing mode of build/bdist.linux-s390x/wheel/pylink_square-1.2.0.data/scripts/pylink-rtt to 755 2024-03-28 12:01:37,247 root INFO changing mode of build/bdist.linux-s390x/wheel/pylink_square-1.2.0.data/scripts/pylink-swv to 755 2024-03-28 12:01:37,248 wheel INFO creating build/bdist.linux-s390x/wheel/pylink_square-1.2.0.dist-info/WHEEL 2024-03-28 12:01:37,248 wheel INFO creating '/home/buildozer/aports/community/py3-pylink-square/src/pylink-square-1.2.0/.dist/.tmp-arqy_h2p/pylink_square-1.2.0-py2.py3-none-any.whl' and adding 'build/bdist.linux-s390x/wheel' to it 2024-03-28 12:01:37,248 wheel INFO adding 'pylink/__init__.py' 2024-03-28 12:01:37,249 wheel INFO adding 'pylink/__main__.py' 2024-03-28 12:01:37,249 wheel INFO adding 'pylink/binpacker.py' 2024-03-28 12:01:37,249 wheel INFO adding 'pylink/decorators.py' 2024-03-28 12:01:37,249 wheel INFO adding 'pylink/enums.py' 2024-03-28 12:01:37,249 wheel INFO adding 'pylink/errors.py' 2024-03-28 12:01:37,249 wheel INFO adding 'pylink/jlink.py' 2024-03-28 12:01:37,250 wheel INFO adding 'pylink/jlock.py' 2024-03-28 12:01:37,250 wheel INFO adding 'pylink/library.py' 2024-03-28 12:01:37,250 wheel INFO adding 'pylink/registers.py' 2024-03-28 12:01:37,250 wheel INFO adding 'pylink/structs.py' 2024-03-28 12:01:37,250 wheel INFO adding 'pylink/threads.py' 2024-03-28 12:01:37,250 wheel INFO adding 'pylink/util.py' 2024-03-28 12:01:37,250 wheel INFO adding 'pylink/protocols/__init__.py' 2024-03-28 12:01:37,250 wheel INFO adding 'pylink/protocols/swd.py' 2024-03-28 12:01:37,251 wheel INFO adding 'pylink/unlockers/__init__.py' 2024-03-28 12:01:37,251 wheel INFO adding 'pylink/unlockers/unlock_kinetis.py' 2024-03-28 12:01:37,251 wheel INFO adding 'pylink_square-1.2.0.data/scripts/pylink-rtt' 2024-03-28 12:01:37,251 wheel INFO adding 'pylink_square-1.2.0.data/scripts/pylink-swv' 2024-03-28 12:01:37,251 wheel INFO adding 'pylink_square-1.2.0.dist-info/LICENSE.md' 2024-03-28 12:01:37,251 wheel INFO adding 'pylink_square-1.2.0.dist-info/METADATA' 2024-03-28 12:01:37,251 wheel INFO adding 'pylink_square-1.2.0.dist-info/WHEEL' 2024-03-28 12:01:37,251 wheel INFO adding 'pylink_square-1.2.0.dist-info/entry_points.txt' 2024-03-28 12:01:37,251 wheel INFO adding 'pylink_square-1.2.0.dist-info/top_level.txt' 2024-03-28 12:01:37,251 wheel INFO adding 'pylink_square-1.2.0.dist-info/RECORD' 2024-03-28 12:01:37,252 wheel INFO removing build/bdist.linux-s390x/wheel 2024-03-28 12:01:37,252 gpep517 INFO The backend produced .dist/pylink_square-1.2.0-py2.py3-none-any.whl pylink_square-1.2.0-py2.py3-none-any.whl ============================= test session starts ============================== platform linux -- Python 3.11.8, pytest-8.1.1, pluggy-1.4.0 rootdir: /home/buildozer/aports/community/py3-pylink-square/src/pylink-square-1.2.0 collected 442 items / 5 deselected / 437 selected tests/unit/protocols/test_swd.py .......... [ 2%] tests/unit/test_binpacker.py ..... [ 3%] tests/unit/test_decorators.py .... [ 4%] tests/unit/test_enums.py ....... [ 5%] tests/unit/test_errors.py .. [ 6%] tests/unit/test_jlink.py ............................................... [ 17%] ........................................................................ [ 33%] ........................................................................ [ 50%] ........................................................................ [ 66%] ........................................................ [ 79%] tests/unit/test_jlock.py ........ [ 81%] tests/unit/test_library.py ........................ [ 86%] tests/unit/test_main.py .................... [ 91%] tests/unit/test_structs.py .................... [ 95%] tests/unit/test_threads.py . [ 96%] tests/unit/test_util.py ......... [ 98%] tests/unit/unlockers/test_unlock.py .. [ 98%] tests/unit/unlockers/test_unlock_kinetis.py ...FF. [100%] =================================== FAILURES =================================== _______________ TestUnlockKinetis.test_unlock_kinetis_read_fail ________________ self = mock_sleep = @mock.patch('time.sleep') def test_unlock_kinetis_read_fail(self, mock_sleep): """Tests unlock Kinetis failing during a read. At any point, the unlock can fail if it tries to read from the an MDM-AP register and a fault occurs. Args: self (TestUnlockKinetis): the `TestUnlockKinetis` instance mock_sleep (Mock): mocked `time.sleep()` function Returns: `None` """ mock_jlink = mock.Mock() mock_jlink.tif = enums.JLinkInterfaces.SWD flags = (0x2 << 28) | (0xBA01 << 12) | 1 mock_jlink.coresight_read.side_effect = [flags, 0xFF] mock_jlink.swd_write.return_value = 0 # ACK mock_jlink.swd_read8.return_value = -1 # Invalid Read mock_jlink.swd_read32.return_value = 2 # Data res = unlock.unlock_kinetis(mock_jlink) self.assertFalse(res) > self.assertEqual(1, mock_jlink.set_reset_pin_low.call_count) E AssertionError: 1 != 0 tests/unit/unlockers/test_unlock_kinetis.py:157: AssertionError ________________ TestUnlockKinetis.test_unlock_kinetis_success _________________ self = mock_sleep = @mock.patch('time.sleep') def test_unlock_kinetis_success(self, mock_sleep): """Tests unlock Kinetis succesfully unlocking the device. Args: self (TestUnlockKinetis): the `TestUnlockKinetis` instance mock_sleep (Mock): mocked `time.sleep()` function Returns: `None` """ mock_jlink = mock.Mock() mock_jlink.tif = enums.JLinkInterfaces.SWD flags = (0x2 << 28) | (0xBA01 << 12) | 1 mock_jlink.coresight_read.side_effect = [flags, 0xFF] ack = swd.Response.STATUS_ACK wait = swd.Response.STATUS_WAIT mocked_data = mock.Mock() mocked_data.read_data = [ 0x0, # Wait 0x1, # Ack 0x3, # Flash Ready Bit Set 0x1, # Ack 0x3, # Erase Command Bit Set 0x1, # Ack 0x0, # Flash Erase In Progress Bit Cleared ] mocked_data.status_and_parity_data = [ ack, # Error clearing write request. ack, # Selecting the MDM-AP Status Register wait, # First poll, wait ack, # Second poll, continue 0x1, # Parity ack, # Flash Ready ACK 0x0, # Flash Ready Parity 0x1, # Mass Erase Request ack, # Erase Command ACK 0x1, # Erase Command Parity ack, # Erase Command ACK 0x0, # Erase Command Parity ack, # Flash Erase Command ACK 0x1, # Flash Erase Command Parity ack, # Flash Erase Command ACK 0x0, # Flash Erase Command Parity ] # ACK mock_jlink.swd_write.return_value = 0 # Status and Parity mock_jlink.swd_read8.side_effect = mocked_data.status_and_parity_data # Data mock_jlink.swd_read32.side_effect = mocked_data.read_data res = unlock.unlock_kinetis(mock_jlink) > self.assertTrue(res) E AssertionError: False is not true tests/unit/unlockers/test_unlock_kinetis.py:221: AssertionError =========================== short test summary info ============================ FAILED tests/unit/unlockers/test_unlock_kinetis.py::TestUnlockKinetis::test_unlock_kinetis_read_fail FAILED tests/unit/unlockers/test_unlock_kinetis.py::TestUnlockKinetis::test_unlock_kinetis_success ================= 2 failed, 435 passed, 5 deselected in 1.06s ================== >>> ERROR: py3-pylink-square: check failed >>> py3-pylink-square: Uninstalling dependencies... (1/39) Purging .makedepends-py3-pylink-square (20240328.120136) (2/39) Purging py3-psutil-pyc (5.9.8-r0) (3/39) Purging py3-psutil (5.9.8-r0) (4/39) Purging py3-six-pyc (1.16.0-r8) (5/39) Purging py3-six (1.16.0-r8) (6/39) Purging py3-gpep517-pyc (15-r1) (7/39) Purging py3-gpep517 (15-r1) (8/39) Purging py3-installer-pyc (0.7.0-r1) (9/39) Purging py3-installer (0.7.0-r1) (10/39) Purging py3-setuptools-pyc (69.2.0-r0) (11/39) Purging py3-setuptools (69.2.0-r0) (12/39) Purging py3-wheel-pyc (0.42.0-r0) (13/39) Purging py3-wheel (0.42.0-r0) (14/39) Purging py3-mock-pyc (5.1.0-r1) (15/39) Purging py3-mock (5.1.0-r1) (16/39) Purging py3-pytest-pyc (8.1.1-r0) (17/39) Purging py3-pytest (8.1.1-r0) (18/39) Purging py3-iniconfig-pyc (2.0.0-r0) (19/39) Purging py3-iniconfig (2.0.0-r0) (20/39) Purging py3-packaging-pyc (24.0-r0) (21/39) Purging py3-packaging (24.0-r0) (22/39) Purging py3-parsing-pyc (3.1.2-r0) (23/39) Purging py3-parsing (3.1.2-r0) (24/39) Purging py3-pluggy-pyc (1.4.0-r0) (25/39) Purging py3-pluggy (1.4.0-r0) (26/39) Purging py3-py-pyc (1.11.0-r2) (27/39) Purging py3-py (1.11.0-r2) (28/39) Purging python3-pyc (3.11.8-r0) (29/39) Purging python3-pycache-pyc0 (3.11.8-r0) (30/39) Purging pyc (3.11.8-r0) (31/39) Purging python3 (3.11.8-r0) (32/39) Purging gdbm (1.23-r1) (33/39) Purging libbz2 (1.0.8-r6) (34/39) Purging libffi (3.4.6-r0) (35/39) Purging libpanelw (6.4_p20240309-r0) (36/39) Purging mpdecimal (4.0.0-r0) (37/39) Purging readline (8.2.10-r0) (38/39) Purging sqlite-libs (3.45.2-r0) (39/39) Purging xz-libs (5.6.1-r1) Executing busybox-1.36.1-r24.trigger OK: 346 MiB in 107 packages