I advanced a little bit in the debugging, but I still can’t figure this out.
I have here my 3 layers. The two that look black and white cannot compute histogram. The one that looks good, can.
However, not only the computation for each band was done using the same logic, but if you use Pixel Info you can see that images that look like masks they actually have valid values.
I’ve run into this exact error before. Usually, it’s just a matter of the data not being fully indexed yet. Re-importing the product or checking the ‘No-Data’ value settings in the properties usually does the trick for me.