Personally, I think a politician (and a person generally) should be allowed to change their mind. As we learn more, become wiser or look at things from another perspective, naturally we should change our mind. We don't form all our opinions at birth, nor do we stop forming views as we grow older, although I am certain some people on this forum will never change some of their opinions! This is a kettle speaking.
However, to intentionally tell an untruth (I'm practicing political correctness today, so I didn't use the word "lie"

) for one's personal gain e.g. to tell an untruth before an election to gain votes, would in most cases probably be unethical.
I think it is usual for many senior people starting a new job, to say "The situation is worse than I knew, so I can't do all I promised." Often there is an element of truth is this, but only partial. To blame ones' predecessor and reduce the expectation of ones' boss, is very common today. Most newly elected Prime Ministers take this approach in Australia. Very few people believe them, but what can we do about it?