Dog food is not good for roaches, not sure about crickets. It tends shorten roaches life spans and gives them liver/kidney disease. Dubia and I think other most tropical roaches are naturally frugavious(sp?) In other words they eat fruit and veggies more than protein. Protein causes them to breed more, but its not good for theme in the long run, female roaches can live for almost 2 years when taken good care of.
It is good for them, they need it. They do not need large amounts, they need averaging amounts. By averaging, I mean around 20-30% in there diet. 5% is too little and 60% is too much. (it may I know it has alot)
Cat food has too much, dog food has in the ranges of 20-30%, also most people do not give only dog food. But dog food mixed with other things, to provide protein.
Not giving Animal protein to a roach is just as bad as giving too much. Kidney and liver failure can be caused by too much protein, however I dont even think straight cat food has enough to do that.
Here is a great article about it,
https://dubiaroachdepot.com/guidance/dubia-roaches-dietary-protein.
So as that says, roaches need animal protein from meats ect to survive. This is accomplished with cat food dog food fish food chicken food ect. In the wild they eat decomposing dead animals to fill this need. So while yes they do eat primarily fruit. That is due to there other diet which is dead animals to store into there protein stores. They need protein.
However feeding roaches that are fed a proper protein diet to cham is also bad as the uric acid they make can cause liver kidney issues and Gout ect, in chameleons who need low protein.
That said that study does show that roaches not fed protein live longer. However we do not want a longer life, we want them to breed more. Which roaches with no protein do not do. even if you could get them to breed more and live longer to what means? They only breed for about 75% of there life. After about 1.5 years breeding is over for that roach, what point is there to keep feeding it?
There is a big difference between keeping as a pet and keeping as food.