warning on reflection checked and type hints improved