The Lehner trade is simple. Anderson wasn't/still isn't ready to step down and has been better than Lehner over the last few years.
Lehner has enormous potential, but was inconsistent, and hadn't developed enough to take over when the Sens felt they were ready to be a playoff team. They needed to play the best goalie over the next few years, which in 2015 was Anderson, and without starts, Lehner was never going to develop.
He was sent to a team that was earlier in their rebuild and thus a better fit for him. Lehner is a great prospect who should go on to be Buffalo's solution in net, but Ottawa got an equally as good prospect in Colin White and was also able to clear 3.5M in salary space via dumping David Legwand's contract to Buffalo.
It is also important to mention, trading Lehner might have been important in convincing Matt O'Connor who at the time was a decent coup (now, maybe not so much but there's still time) to sign. The Sens also got to keep Andrew Hammond who if Lehner wasn't traded most likely would have walked as a UFA and signed a 1 way deal else where since he was coming off of that huge run and even if there was a good chance he wasn't anywhere near the goalie he looked like over 20ish games, someone would have given him a chance as a free agent.
As far as the Bishop trade goes, the most I can say to defend it is that it is easy for us to sit there and laugh at it years later, but go back and read threads from the time and see what people thought about it. Does that mean it isn't a bad trade? No. It has panned out to be one of the worst trades in Sens history. The team gift wrapped a division rival a very good goalie and got what amounted to a bit of help at forward at the end of the shortened season and a 4th rounder in return. But it is easy to see why someone running a team with 3 goalies, one being a young goalie of the future and the other being a solid veteran starter might make that move at the time. If people were really in touch with what Bishop would become, there would have been teams out there willing to top Tampa's offer, particularly Edmonton who cheaped out on acquiring him. I don't quite remember, but I think Ottawa may have wanted the earlier of Edmonton's two second round picks, and EDM turned down Bishop over that.