Bugfixes & better logging

The capacity warnings explode in log files, I've added some logic that makes them more gentle. Also fixed a few bugs/redundancies.