We learnt that Moses has asked to see God's glory (Exodus 33:18). God grants his desire, but protects Moses from His Shekinah glory so Moses would not die. God showed Moses such compassion, abounding in love and grace in that moment.
It has everything to do with Grace, God gave Moses his desire though it was dangerous, but shield him while granting his wish.