I think the dichotomy comes from some people equating “CICO” with “all calories are the same” - which is not accurate. People will bring up the “100 calories of broccoli versus 100 calories of sugar” to explain why a calorie is not a calorie.
Also, the way your body uses fats, proteins, and carbs are different, and they even require different levels of energy just to process them. So 100 protein calories and 100 carb calories are definitely not the same. It takes more calories to process the protein eaten, and it is used more for body maintenance and muscle building and not so much as energy burned for activity. The exception is when you eat enough extra protein than your body needs, in which case it converts the protein to something useful (glucose).
So but let’s say you are eating a low carb, medium protein, relatively higher fat diet, and choosing healthy real foods to achieve that. THEN, within that context, CICO can come into play. Suppose you increase your CO by exercising more, without unconsciously eating more because the exercise increases your appetite. Then you would certainly expect to lose some weight.
Similarly, if you added another 500 fat calories on top of what you were eating (without increasing your exercise) you would expect to gain some weight as the body has all the fat it needs from your diet, plus some more for it to store.
There was an interesting experiment (https://www.dietdoctor.com/what-happens-if-you-eat-5800-calories-daily-on-an-lchf-diet) where a healthy-weight man chose to overeat a specific number of calories from fats over a period of time and gained about 4 pounds. CICO predicted 16 pounds. He repeated the same experiment with the same number of excess calories, but from carbs, and gained about 16 pounds, which was in line with the CICO numbers.
So while I think calories do matter, it seems to not just a pure CICO equation where all calories are identical, and the equation may only apply to otherwise healthy individuals with normal metabolisms.