[elbe-devel] [PATCH v2 00/15] Issue 172 - use check_call instead of os.system

dion at linutronix.de dion at linutronix.de
Mon Jun 24 17:38:57 CEST 2019


From: Olivier Dion <dion at linutronix.de>

See https://github.com/Linutronix/elbe/issues/172

> check_call raises an exception. Please replace all os.system calls
> that return code is not checked with check_call(..., shell=True) to
> improve error handling."

All calls to os.system were not checked, this might result in new
exceptions that weren't there before.

All calls to os.system and check_call were change to
shellhelper::system to we can send logging message in the futur.

Olivier Dion (15):
  Change os.sytem to shellhelper::system for "check_updates.py"
  Change os.sytem to shellhelper::system for "chroot.py"
  Change os.sytem to shellhelper::system for "init.py"
  Change os.sytem to shellhelper::system for "toolchainextract.py"
  Change os.sytem to shellhelper::system for "barebox.py"
  Change os.sytem to shellhelper::system for "kernel.py"
  Change os.sytem to shellhelper::system for "debpkg.py"
  Change os.sytem to shellhelper::system for "efilesystem.py"
  Change os.sytem to shellhelper::system for "elbeproject.py"
  Change os.sytem to shellhelper::system for "initvmaction.py"
  Change os.sytem to shellhelper::system for "updated.py"
  Change os.sytem to shellhelper::system for "updatedpkg.py"
  Change os.sytem to shellhelper::system for "virtapt.py"
  Change check_call to shellhelper::system for "uboot.py"
  Change check_call to shellhelper::system for "archivedir.py"

 elbepack/archivedir.py                |  5 ++--
 elbepack/commands/check_updates.py    |  6 ++---
 elbepack/commands/chroot.py           |  5 ++--
 elbepack/commands/init.py             | 14 ++++------
 elbepack/commands/toolchainextract.py |  4 ++-
 elbepack/debianize/barebox.py         |  3 ++-
 elbepack/debianize/kernel.py          |  3 ++-
 elbepack/debianize/uboot.py           |  4 +--
 elbepack/debpkg.py                    | 21 +++++++--------
 elbepack/efilesystem.py               | 50 +++++++++++++++++++----------------
 elbepack/elbeproject.py               |  6 +++--
 elbepack/initvmaction.py              |  3 ++-
 elbepack/updated.py                   |  9 ++++---
 elbepack/updatepkg.py                 | 13 ++++-----
 elbepack/virtapt.py                   |  7 ++---
 15 files changed, 79 insertions(+), 74 deletions(-)

-- 
2.11.0




More information about the elbe-devel mailing list