Heisenbug Fix, Dependency Bumps and various Refactorings

Please refer to the commit list for details.

=Dusan