Infallibility of the Prophets (as) and Imams (as) can get confusing for me at times. Maybe you can help me in clearing the seeming contradictions that I appear to see.

1. The story of Prophet Adam’s (as) expulsion from the Garden. If a prophet is ma’sum, how can he go against the express wishes of Allah.

2. The incident of Aisha being left behind from a caravan. I read that Imam Ali (as) suggested to the Prophet (saww) that in case there was doubt on her chastity, then divorce was an option. I find it difficult to see this incident as factual. For one, if the Imams and the Prophets have knowledge of the unseen and are ma’sum, how could Imam Ali suggest such an option? And why would Rasul Allah (saww) need to refer to anybody when he (saww) would most likely know the answer already.

3. The story of Prophet Yunus (as). That he abandoned his people and sailed away. This caused him to end up in the belly of a whale, since he abandoned his people before any command from Allah. How can a ma’sum prophet make such an error?

Obviously my knowledge is limited, as these incidents appear to contradict infallibility. Please clear my confusions. And any reading material in English that you can recommend would be helpful to me.

1- Prophet Adam did not sin. You can see this video for an explanation:

2- This claim about Imam Ali (a) suggesting to the Prophet (s) to divorce her is narrated in Sunni sources. We don’t have an authentic hadith that states he did, so we cannot confirm he did. There is no evidence for it. Assuming he did, it’s not because Imam Ali (a) doubted her chastity. It was probably because this issue caused a major headache for the Prophet (s), and so the Imam suggested she gets divorced to put an end to the whole controversy. It does not negate his infallibility.

3- As for Prophet Yunus (a), he did not commit a sin by leaving his people. His people were acting in a very evil way and they deserved punishment. Yes, he should have been more patient with them, but by leaving them he did not do anything wrong. Scholars state prophets sometimes commit Tark al-Awla, which means they don’t choose the best choice. Sometimes you have two choices to make. Choosing any of them is not a sin but one is better than the other. Sometimes prophets would not choose the best option. But they are still infallible. They would not violate the law of God.