Don't forget annot modes when doing a pack compilation.
fix typo in exception name.