The first time I went there, the Jesuit who was accompanying me told me that Galileo had visited this place, and that the story of church vs. science that we've all learnt in school was very simplified. Apparently Riccioli defended a hybrid geo-heliocentric model (due to Tycho Brahe) where the earth is at the center of the universe, the sun and moon revolve around it, but all the other planets revolve around the sun. We now know neither the sun, nor the earth is at the center of the universe, so both models were equally wrong, however according to my Jesuit guide, Riccioli's point of view was the only one that would have been both theologically acceptable and scientifically sound.
I guess what is really wrong about the classical story of Galileo's trial is that the catholic church is not and never was a monolithic entity: there are factions, dissent, political agendas.
If you're interested in further reading on Riccioli the Wikipedia page is very detailed:
https://en.wikipedia.org/wiki/Giovanni_Battista_Riccioli#Arg...