Traditionally, yes. The Olympic spirit is to be willing to push yourself as hard as necessary, through anything, even to the point of death, to win the gold. Quitting only brings shame and disgrace to you and your country.
I agree with what Simone Biles did, and I don't think anyone can judge her - only she knows what her headspace and capabilities were - but it was absolutely against what the Olympic spirit is supposed to be. Olympic competition often serves as a form of neo-eugenic nationalist propaganda (that our nation and its values creates genetically superior people and potential combatants to yours.) Imagine the furor if this were the 1980s and Simone Biles had quit and a Soviet gymnast had won the gold medal. Everyone in the US would be calling her a traitor and a coward.
I also think that this decision took a lot of bravery for Biles. And I admire her for that.