How do mathematicians view counter examples? Is it like an unexpected result in the physical sciences: annoying in the moment but potentially stupendously important as it reveals some inaccuracy in the current models? Or is it more like a bug report in coding… probably just, another little annoying detail?

Counterexamples are clarifying. For everyone condition in a proof, it's really handy to have a maximally simple, memorable counterexample that makes it fail because it violates that condition. Mathematicians tend to walk around with a bestiary of counterexamples in their heads. It also makes it really easy to recover a theorem because you try to sketch out the statement, and the spiky, memorable counterexamples jump out of your memory and you add conditions to constrain the domain away from them.

I am sure finding holes in existing proofs is what counts as "another little annoying detail". Some people are probably relieved when they have failed to prove a hypothesis and someone finds a counterexample.

There are pedagogical books (CF. 'Counterexamples in Topology', 'Counterexamples in Analysis') that teach the nuances of subjects through counterexamples. They're popular as it's sometimes easier to learn details from a pathology or degenerate example than from just learning what is intended.