In the totality of the context of scripture from an exegetical perspective this prophecy:
“The righteous man perishes, and no one lays it to heart; devout men are taken away, while no one understands. For the righteous man is taken away from calamity; he enters into peace; they rest in their beds who walk in their uprightness.” - Isaiah 57:1-2
is how this prophecy:
“Because you have kept my word about patient endurance, I will keep you from the hour of trial that is coming on the whole world, to try those who dwell on the earth.” - Revelation 3:10
is fulfilled by the end of this age before the great tribulation for those that, but for God calling them home, were of the age and generation that would have experienced that event. It is not fulfilled by a pre-tribulation-rapture that starts the great tribulation (Matthew 24:21-22) as many teach and believe. And this prophecy is only fulfilled for those that have never strayed from the way of the Lord and deliberately kept on sinning for any period of time and or intermittently after entering into covenant with God through Christ by the Baptism of water and Spirit.
The rest of us that are alive at the start of the great tribulation and are faithful believers despite our continued transgressions after our public confession (1 John 2:1-2), as the Revelation shows, but who will not worship the image of the beast or receive his mark (Revelation 13:11-17; 14:9-12), will be saved as Daniel’s friends were during their exile in Babylon through the fire and not from it (Daniel 3:8-30), and as the Israelites were saved through the Red Sea after being saved from the Angel of Death to the first born in Egypt into the wilderness, - The Passover Lamb and Feast representing salvation from our inheritance of sin (our inherited death as the children of Adam) and the first death through the body and blood of Christ, - while deliverance from the army of Pharoah through the Red Sea is our Baptism of Death (Romans 6:3) which represent our deliverance from the second death. The entry into the Promise Land was representative of our redemption of the promise (Ephesians 1:13-14).