I have seen some historians, even on this sub, disputing the naming of the medieval ages as the "Dark Ages" and notions that Christianity actively suppressed scientific knowledge during said periods. That Christian churches were centers of knowledge and that there were even monks that argued for a round earth. I had a brief discussion with a professor today about people being burned on the stake for seeking knowledge.
So how truthful or widespread were these alleged heretical burnings and was it common place as popular culture makes some people think it was?
There are two issues here:
At various times in its Medieval history, the Catholic Church and its allies did engage in religious wars against what it called heresy, paganism, and protestantism. This involved massive persecutions of groups of people for their political affiliations and religious beliefs, including, at times, the burning of people at the stake for advocating certain theological positions. The reason why they bothered is because the theological and the political were often the same thing at this time, for the Church. Many of these actions, esp. during the Medieval period, were super brutal, arguably (as in the case of the persecution of the Cathars) falling into the category of genocides.
At various times in its history, the Catholic Church did decree that certain statements about the natural world, like the model of the solar system, were in fact theological/philosophical positions, and thus were regulated in the areas of its control as if they were political positions. This is largely something that happened later than the Medieval period (more like the Early Modern period), but the line between a scientific position and a theological one has always been blurry (because science tries to describe the natural world, and theology frequently contains explanations of the natural world as well — e.g., "where we come from"), and still is (it is not a coincidence that many climate change deniers essentially appeal to the Bible as further backing to their claim).
So there are some places where there is an overlap between the two. It was not a decree against seeking knowledge or even researching "heretical" scientific theories, but there were (again, at specific times) decrees against teaching or publishing in favor of some of them. And there were some people whose persecutions, like Giordano Bruno (the most famous "burned at the stake" person in this area), where the difference between a theological and a scientific position were blurry, and so they are sometimes claimed as a martyr for science (but that requires ignoring all of the other reasons they burned him at the stake, too).
In general, the idea that the Catholic Church persecuted scientific research is overblown and untrue. The Catholic Church was, in reality, the largest patron of scientific research in the Medieval period (and some time after). Jesuit astronomers, for example, tend to be ignored by latter-day scientists looking for heroes, but they were the major force who wrote the textbooks, engaged with the research, and read the articles of the "heretics" like Galileo. And contrary to popular opinion, they could be convinced in the face of strong evidence, and indeed the Church itself did change its own positions on these matters several times (e.g., they moved from a Ptolemaic system to a Tychonic system, the latter of which fit the same evidence as the Copernican system). Rather than being just a stodgy organization obsessed with dogma, they endorsed what we call natural theology for much of their history: the idea that the study of the works of nature is the study of the works of God, and understanding nature is understanding God. This was a motivating belief for the vast majority of Medieval and Early Modern "scientists" (if we want to use the term broadly), including people inside and outside of Catholic lands (e.g., this is why Isaac Newton did his thing, too).
The problem is that most popular histories of science of this (long) period focus on a handful of these "scientific heroes," a few of whom ran afoul of the Church. I mentioned Bruno, but of course Galileo is really the one that most people focus on. And the Galileo affair is just a complicated mess of politics, personal relationships, and, of course, the line between astronomy and philosophy. Without seeking to vilify Galileo (he was basically a jerk and finally went over the line at a time when the Church was feeling insecure and needed to enforce its authority) or exonerate the Church (threatening an old man with torture, and then putting him under lifetime house arrest, is an extreme response for someone being a jerk), one can say that it was a complicated situation and should not be taken as representative for the entire relationship between the Church and science, esp. not in the Medieval period (it is in what we call the Early Modern period anyway — it's not Medieval at all).
Like all things in history, the relationship between the Church and science was pretty complicated. Sometimes the Church was a huge supporter. Sometimes it put scientific texts (like Copernicus' book) on the "Index" of banned books (though, interestingly, it only did that a century or so after it was published, because nobody really paid it much attention originally). Similarly, if one looks at the scientists in question, some of them were doing what we would call "objective science" today, but many of them were deliberately treading into theological territory. (Johannes Kepler, for example, was in fact about as "heretical" as you can get — to the point of people like Galileo thinking he was potentially a whacko. Kepler was an explicit sun-worshipper who believed that the solar system worked the way it did because of the music of the stars, which was not, in any way, a metaphor or analogy — literally music. The thing is, he was also a great mathematician, so his work was super important, but he went about it for these reasons we would consider very unusual — and definitely not scientific — today.) So the Church saying, "these supposed scientific claims look like they are also philosophical or theological claims" — they aren't really wrong. They often were meant to be both, or, even when they weren't meant to be both, in fact were both (the preference of a Copernican model over a Tychonic one, at that time, cannot be ascribed to evidence, it is more of a philosophical preference).
So at various places (Catholic-controlled lands) and times (during the wars of Reformation in particular), yes, if you were someone working on an area of science, you'd want to make sure what you were doing was considered kosher by the standards of the Church, or at least try to dress it up like it was (Copernicus' work, for example, contains an extended introduction that basically says, "hey, it's just math, don't freak out — definitely no philosophy or theology in here, just a guy playing with numbers!"). And at various times, if you ran afoul of that, there could be consequences, though the severest consequences appear to have been reserved for people who ran afoul in multiple ways, repeatedly (e.g., not just for the science, but all of the other stuff, too). And, again, it should be repeated that the Catholic Church actually funded and encouraged scientific research for most of this period as well — even if it was expected that its conclusions would fall into some reasonable interpretation of the scripture that already existed.
So it's a historically mixed-bag, spread out over centuries and many different locations and people — so some simplistic, "they were just bad" or "they were just good" story doesn't really emerge. It's further complicated by the fact that these singular cases (Bruno, Galileo, etc.) are of course quite singular and not themselves representative of hundreds of years of history, either. It is hard to make generalizations about "the Church and science" any more than it would be possible to make generalizations about "the US state and science" (sometimes it supports it, sometimes it doesn't, it depends on the time, place, context, and even how one interprets "support").
Ronald Numbers' Galileo Goes to Jail and Other Myths about Science and Religion is a great place to get more about the complexity of all of this.