supressed deprecation warnings and removed unused imports