Is valuing one field over another is a common behavior in academia?
The other answers clearly answer yes. There can be subjective reasons to such an observation (e.g., a cardiologist could feel more superior to a gastroenterolog), but there might be also an objective part to the observation (as you example goes, the results produced in software engineering are somewhat shakier than those in graph theory).
How does one avoid thinking that way?
Besides an excellent point by other answer saying "you should try to better understand the challenges of the other field", I also argue that you should better understand the dynamics of scientific pursuit in general.
Kuhn, in the Structure of Scientific Revolutions argues that scientific work in any given field has three phases. The first, pre-paradigm and subsequent transition to normal science are relevant for this answer:
The first phase, which exists only once, is the pre-paradigm phase, in which there is no consensus on any particular theory, though the research being carried out can be considered scientific in nature. This phase is characterized by several incompatible and incomplete theories. If the actors in the pre-paradigm community eventually gravitate to one of these conceptual frameworks and ultimately to a widespread consensus on the appropriate choice of methods, terminology and on the kinds of experiment that are likely to contribute to increased insights, then the second phase, normal science, begins, in which puzzles are solved within the context of the dominant paradigm. Etc.
Often we observe somewhat substandard results and works in fields which clearly fall into the category of those still being in the pre-paradigm phase. Your specific question is relevant to this due to the fact, that whole of computer science is still a young field and many problems we are solving are new, often vague, or ill defined, etc. This is is especially the case for the fields and communities tackling applications of applied-mathematics-style computer science to real-world applications, i.e., software engineering. Your reference to software engineering is clearly the case here, large parts of artificial intelligence fall into this category as well, and I am sure other fields and subfields too.
Even if you find yourself working in a "soft" field, it does not necessarily mean the niche community is not tackling a sound problem (though sometimes it is the case, but you need to look very carefully into it). Sometimes working on such can be even more demanding/challenging/satisfying than routinely solving puzzles in the normal-science context.