dpkg's job is to leave the system in a recoverable state when this sort of thing happens; I don't think it should get into the job of predicting how much disk space is available. That seems more like a job for higher-level tools like update-manager.
If dpkg didn't say "No more space on device", then that genuinely wasn't the error code it got from the kernel and/or the C library, though ... without an exact message it isn't possible to diagnose that problem further.
dpkg's job is to leave the system in a recoverable state when this sort of thing happens; I don't think it should get into the job of predicting how much disk space is available. That seems more like a job for higher-level tools like update-manager.
If dpkg didn't say "No more space on device", then that genuinely wasn't the error code it got from the kernel and/or the C library, though ... without an exact message it isn't possible to diagnose that problem further.