fix compatibility issues with python-apt < 0.7.9