Fixes login. Renamed User.is_active to User.active
fixed imports in tests
fixes import