#1804 Do not fail on unicode decoding errors in command output
Closed: Fixed by siosm. Opened by siosm.

rpm-ostree composes sometimes output unexpected characters while running scriptlets. I'm not sure if this is rpm-ostree or the scriptlet fault right now.

But ideally, pungi should not fail on weird output and instead should ignore it / skip it.

See: https://pagure.io/releng/issue/12474

DEBUG util.py:463:  systemd-udev.post: Created symlink '/etc/systemd/system/multi-user.target.wants/systemd-homed.service'  '/usr/lib/systemd/system/systemd-homed.service'.
DEBUG util.py:463:  systemd-udev.post: Created symlink '/etc/systemd/system/systemd-homed.service.wants/systemd-homed-activate.service'  '/usr/lib/systemd/system/systemd-homed-activate.service'.
DEBUG util.py:463:  systemd-udev.post: CreateTraceback (most recent call last):
DEBUG util.py:463:    File "/usr/bin/pungi-make-ostree", line 33, in <module>
DEBUG util.py:463:      sys.exit(load_entry_point('pungi==4.7.0', 'console_scripts', 'pungi-make-ostree')())
DEBUG util.py:463:               ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
DEBUG util.py:463:    File "/usr/lib/python3.13/site-packages/pungi/ostree/__init__.py", line 202, in main
DEBUG util.py:463:      func()
DEBUG util.py:463:      ~~~~^^
DEBUG util.py:463:    File "/usr/lib/python3.13/site-packages/pungi/ostree/tree.py", line 155, in run
DEBUG util.py:463:      self._make_tree()
DEBUG util.py:463:      ~~~~~~~~~~~~~~~^^
DEBUG util.py:463:    File "/usr/lib/python3.13/site-packages/pungi/ostree/tree.py", line 62, in _make_tree
DEBUG util.py:463:      shortcuts.run(
DEBUG util.py:463:      ~~~~~~~~~~~~~^
DEBUG util.py:463:          cmd,
DEBUG util.py:463:          ^^^^
DEBUG util.py:463:      ...<3 lines>...
DEBUG util.py:463:          universal_newlines=True,
DEBUG util.py:463:          ^^^^^^^^^^^^^^^^^^^^^^^^
DEBUG util.py:463:      )
DEBUG util.py:463:      ^
DEBUG util.py:463:    File "/usr/lib/python3.13/site-packages/kobo/shortcuts.py", line 347, in run
DEBUG util.py:463:      lines = proc.stdout.read(buffer_size)
DEBUG util.py:463:    File "<frozen codecs>", line 325, in decode
DEBUG util.py:463:  UnicodeDecodeError: 'utf-8' codec can't decode bytes in position 0-1: invalid continuation byte
DEBUG util.py:610:  Child return code was: 1

Should be fixed with https://pagure.io/pungi/pull-request/1812

Metadata Update from @siosm:
- Issue close_status updated to: Fixed
- Issue status updated to: Closed (was: Open)

This issue has been migrated to Fedora Forge:
https://forge.fedoraproject.org/pungi/pungi/issues/1804

Please continue any further discussion there.

Metadata