Fixed generate-events task