volitank / nala

Nala is a front-end for libapt-pkg.
GNU General Public License v3.0
1.33k stars 49 forks source link

If uninstaller has interactive prompt, nala waits for input but doesn't show it #32

Closed Random-Chain closed 5 months ago

Random-Chain commented 6 months ago

Running nala 0.14.0 on Pop!_OS 22.04.

Seems that when an uninstall script has some prompt, nala won't show it and it seems to just hang while running. Actually it's waiting for user input in the background and you can progress by pressing enter.

Found this while trying to uninstall a VPN client which asks you if you want to keep some config files.

❯ sudo nala purge pulsesecure (...)
======================================================================================================================================================================================================================================
 Purging                                                                                                                                                                                                                              
======================================================================================================================================================================================================================================
  Package:                                                                    Version:                                                                                                                                         Size:  
(...)
  pulsesecure                                                                 9.1.R15                                                                                                                                        31.0 MB  

======================================================================================================================================================================================================================================
 Summary                                                                                                                                                                                                                              
======================================================================================================================================================================================================================================
 Purge 10 Packages                                                                                                                                                                                                                    

Do you want to continue? [Y/n] y
╭─ Purging Packages ─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
╭─ Purging Packages ─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
(...)                                                         │
│Purging configuration files for pulsesecure (9.1.R15)                                                                                                                                                                               │

### This is where the uninstall hangs, after pressing enter it showed the prompt and kept running ###

│Save all current Pulse Secure configuration settings?[Yy/Nn]^J                                                                                                                                                                      │
│dpkg: warning: while removing pulsesecure, directory '/var/lib/pulsesecure/pulse' not empty so not removed                                                                                                                          │                                                                                                                                          │
│╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮│
││✔ Running dpkg … ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 100.0% • 0:00:00 • 11/11││
│╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯│
╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
Finished Successfully
volitank commented 5 months ago

This should be resolved with release https://gitlab.com/volian/nala/-/releases/v0.15.0