merged Jakub's repo with the main and added error checking to import.