As new as I am to the space of controls engineering, I can say with confidence that upgrading is a double edged sword. On the one hand, the industry of PLC manufacturers is pretty wild where they insist the new and best versions should always be supported and their programming software always needs to be updated, yadda yadda yadda, but on the other, there's obvious improvements in the form of features previously not implemented that can help protect your PLC and machine it's driving. I saw a problem the other day where we were called into a plant whose PLC just shorted because of a thunderstorm (or at least that was the most credible reason for the shut down) and because of a lack of availability due to the discontinued status of the device, we had to buy the same model for a lot of money that could have gone towards the newer models that would have lasted for another decade with better safety features protecting operators, the PLC, and the machine for roughly the same price.
In short, it's a case by case thing, and I wish you all the best in figuring out how to best replace the PLC you're looking to replace