Fix some sad errors (thx for vetal4444); added import_by_path from django 1.6