If to request information about not existent disk with "QUIT command" at the end of request, Parted asks from "my programm": "Need to try again to get request information?".
I and "my programm" think, that Parted already had that answer = "quit"!
Please, remove any interactive events from output if "--machine" parameter exists!
============ Output ===================
address@hidden:/home/user# parted --machine /dev/sdz print quit
Ошибка: Не удаётся получить статус устройства /dev/sdz - Нет такого файла или каталога. ### (translated: Error: Unable to get device status /dev/sdz - There is no such file or directory.)
Повторить/Retry/Отменить/Cancel? cancel
address@hidden:/home/user#
========== End Output ==================