added limit to parsing iterations and added checks for imports