Maybe because much of what started as the goals and methods of "philosophy" were later appropriated and redefined as "science"?
They are both human endeavors to better get at and understand the truth about ourselves, the universe, reality, etc. Philosophy often extends further into realms such as art, morality & ethics, dignity, aesthetics, the role of society, and human nature. Philosophy even takes a meta-view of science, asking how we are justified to even claim to know something to be true at all (epistemology). And for the most part, these questions are answered in terms of and in concert with our scientific understanding.
Moreover, evidence-based science itself is to some degree an outgrowth of Descartes' "method of doubt" and rationalism, then the empiricist philosophical movement, and on and on. It's no wonder that throughout history often the leading scientists/mathematicians and the leading philosophers were the same people.
Concepts such as natural rights, liberty, free will, social justice, etc. all originated in philosophical works, and have indeed "solved problems" by influencing people who are say, in the process of forming secular governments after a political revolution. You can draw a fairly straight line from Plato to Descartes to Hobbes to Locke to the Constitution. When we talk about a "bill of rights" -- where is this concept of a natural human "right" even from? Philosophical theories such as utilitarianism, the meaning of good vs. evil, are used every day in our legal system, economics, politics, and foreign policy.
Moreover, often a breakthrough in science or development in society may have very practical consequences which FORCE people to face unavoidable philosophical questions. Should scientists be legally permitted to clone humans? Should a Tesla kill its own driver to avoid plowing through kids crossing the street? Should there be a minimum wage? Should pharmaceutical companies make life-saving drugs free? When should abortion or infanticide be permitted?
These questions must be answered reasonably-- I'd much rather have them discussed through the lens of rational philosophical discussion rather than religious or purely emotional "go with the gut".
So philosophy has served as an on-ramp to science. But among its benefits, it also helps us move from the descriptive study of the universe to the prescriptive-- to paraphrase the great philosopher Dr. Ian Malcolm-- there's a benefit to moving from the scientific question of if we could to consider the philosophical one of if we should.
Just like there's a "God of the gap"-- a notion that a need for God pushed back as our scientific knowledge expands, so it seems there is a "philosophy of the gap"-- some people seem to redefine "philosophy" to mean useless mental spaghetti that goes nowhere. Do you judge science by the same criteria? Does every "failed" experiment constitute a failure of science?
Given its usefulness, especially as an alternative to religious methods where "science" doesn't offer a clear answer about how people and societies "should" behave, I think damning philosophy too hard is kind of unfair.