first refactoring of old pyload classes