[PATCHv2] Move autopart and installation-specific code outside of __init__.py