Adding logging for amil status and error