Fix dpkg Dependency Errors on Ubuntu Safely
Prefer `apt install ./package.deb` so Ubuntu can resolve repository dependencies in one transaction. If `dpkg -i` already left packages unpacked or unconfigured, diagnose the exact state, repair it without blind removals, and verify the package database.