pmbootstrap/pmb
Andreas Kemnade 8ca71ed3a0
install: do not choke on blockdevices without fs (MR 2153)
when blkid returns 2 while searching for existing pmos installations,
do not abort. That might happen if there is a block device without a
filesystem.

Error given:
(1653851) [21:39:19] (native) % blkid -s LABEL -o value /dev/sdcardp1
(1653851) [21:39:19] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
(1653851) [21:39:19] NOTE: The failed command's output is above the ^^^ line in the log file: /home/andi/.local/var/pmbootstrap/log.txt
(1653851) [21:39:19] ERROR: Command failed: (native) % blkid -s LABEL -o value /dev/sdcardp1
(1653851) [21:39:19] See also: <https://postmarketos.org/troubleshooting>
(1653851) [21:39:19] Traceback (most recent call last):
  File "/home/andi/.local/lib/python3.9/site-packages/pmb/__init__.py", line 49, in main
    getattr(frontend, args.action)(args)
  File "/home/andi/.local/lib/python3.9/site-packages/pmb/helpers/frontend.py", line 314, in install
    pmb.install.install(args)
  File "/home/andi/.local/lib/python3.9/site-packages/pmb/install/_install.py", line 944, in install
    install_system_image(args, 0, f"rootfs_{args.device}", step, steps,
  File "/home/andi/.local/lib/python3.9/site-packages/pmb/install/_install.py", line 586, in install_system_image
    pmb.install.blockdevice.create(args, size_boot, size_root,
  File "/home/andi/.local/lib/python3.9/site-packages/pmb/install/blockdevice.py", line 138, in create
    mount_sdcard(args, sdcard)
  File "/home/andi/.local/lib/python3.9/site-packages/pmb/install/blockdevice.py", line 51, in mount_sdcard
    if previous_install(args, path):
  File "/home/andi/.local/lib/python3.9/site-packages/pmb/install/blockdevice.py", line 27, in previous_install
    label = pmb.chroot.root(args, ["blkid", "-s", "LABEL", "-o", "value",
  File "/home/andi/.local/lib/python3.9/site-packages/pmb/chroot/root.py", line 76, in root
    return pmb.helpers.run_core.core(args, msg, cmd_sudo, None, output,
  File "/home/andi/.local/lib/python3.9/site-packages/pmb/helpers/run_core.py", line 343, in core
    check_return_code(args, code, log_message)
  File "/home/andi/.local/lib/python3.9/site-packages/pmb/helpers/run_core.py", line 219, in check_return_code
    raise RuntimeError("Command failed: " + log_message)
RuntimeError: Command failed: (native) % blkid -s LABEL -o value /dev/sdcardp1
2022-01-02 22:14:06 +01:00
..
aportgen pmb.parse.apkbuild: remove unused args argument (MR 2136) 2021-11-27 14:13:33 +01:00
build build: add support for conflicting dependencies (MR 2146) 2021-12-30 20:25:02 +01:00
chroot build: add support for conflicting dependencies (MR 2146) 2021-12-30 20:25:02 +01:00
config Prepare 1.40.0 release 2021-12-12 19:07:21 +01:00
data pmb: data: keys: sync with Alpine (MR 2131) 2021-10-19 01:44:35 +02:00
export Add 'flasher flash_lk2nd' command (MR 2089) 2021-11-06 20:51:58 +01:00
flasher Add 'flasher flash_lk2nd' command (MR 2089) 2021-11-06 20:51:58 +01:00
helpers Use doas instead of sudo if installed (MR 2091) 2021-12-12 18:46:17 +01:00
install install: do not choke on blockdevices without fs (MR 2153) 2022-01-02 22:14:06 +01:00
parse build: add support for conflicting dependencies (MR 2146) 2021-12-30 20:25:02 +01:00
qemu pmb.qemu.run: workaround for new mkinitfs requirements (MR 2138) 2021-11-06 13:36:34 +01:00
sideload pmb.sideload: support non-standard SSH port (!2046) 2021-04-25 21:04:49 +03:00
__init__.py remove unused args argument (MR 2130) 2021-10-24 14:34:26 +02:00