UNTESTED - make sentry optional.