polish exceptions and platforms (GH-9272)

2 files changed