Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/archinstall.py
diff options
context:
space:
mode:
authorAnton Hvornum <anton.feeds@gmail.com>2019-06-09 20:58:32 +0200
committerAnton Hvornum <anton.feeds@gmail.com>2019-06-09 20:58:32 +0200
commitd533e36b88b6225f5b16dbc436b89cf171570e6b (patch)
treeaa0beca98dcbb338808f6be5da64afc29af8182a /archinstall.py
parentf7cb0b819a087e7171205590678fc8a6da7cadff (diff)
Enhancing debug information for failed command executions
Diffstat (limited to 'archinstall.py')
-rw-r--r--archinstall.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/archinstall.py b/archinstall.py
index 4d91cd9c..a86a9a04 100644
--- a/archinstall.py
+++ b/archinstall.py
@@ -193,8 +193,9 @@ class sys_command():
exit_code = os.waitpid(self.pid, 0)[1]
if exit_code != 0:
- print('[E] Command "{}" exited with status code:'.format(self.cmd[0]), exit_code)
+ print('[E] Command "{}" on line ~150 exited with status code:'.format(self.cmd[0]), exit_code)
print(trace_log)
+ print('[?] Command executed: {}'.format(self.cmd))
exit(1)
def simple_command(cmd, opts=None, *args, **kwargs):
@@ -304,7 +305,8 @@ def grab_partitions(dev):
for part in r['blockdevices'][0]['children']:
size = os.statvfs(dev + part['name'][len(drive_name):])
parts[part['name'][len(drive_name):]] = {
- 'size' : size.f_frsize * size.f_bavail
+ 'size' : size.f_frsize * size.f_bavail,
+ 'blocksize' : size.f_frsize * size.f_blocks
}
return parts