From 80130b4898c3b6eb2b0247ecd3055cadfbf323fa Mon Sep 17 00:00:00 2001 From: Anton Hvornum Date: Sat, 12 Feb 2022 14:51:53 +0100 Subject: [PATCH] Added debug information --- archinstall/lib/general.py | 2 +- archinstall/lib/luks.py | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/archinstall/lib/general.py b/archinstall/lib/general.py index 49d52d6e..daf44e4a 100644 --- a/archinstall/lib/general.py +++ b/archinstall/lib/general.py @@ -335,7 +335,7 @@ class SysCommandWorker: self.ended = time.time() break - if self.ended or (got_output is False and pid_exists(self.pid) is False): + if pid_exists(self.pid) is False: self.ended = time.time() try: self.exit_code = os.waitpid(self.pid, 0)[1] diff --git a/archinstall/lib/luks.py b/archinstall/lib/luks.py index 2005aed2..5e3443c0 100644 --- a/archinstall/lib/luks.py +++ b/archinstall/lib/luks.py @@ -181,12 +181,13 @@ class luks2: os.path.basename(mountpoint) # TODO: Raise exception instead? # print(f"Looking for phrase: 'Enter passphrase for {partition.path}'") - cryptworker = SysCommandWorker(f'/usr/bin/cryptsetup open {partition.path} {mountpoint} --type luks2') + cryptworker = SysCommandWorker(f'/usr/bin/cryptsetup open {partition.path} {mountpoint} --type luks2', peak_output=True) # print(f'Looking for: Enter passphrase for {partition.path}') pw_given = False while cryptworker.is_alive(): if bytes(f'Enter passphrase for {partition.path}', 'UTF-8') in cryptworker and pw_given is False: + print('Entered the passphrase..') cryptworker.write(password) pw_given = True time.sleep(0.25)