FIX: brings back castInteger as a safer migration path for sk2 (PR #8966)

GitHub

You’ve signed the CLA, jjaffeux. Thank you! This pull request is ready for review.