Unfortunately, size is not a very reliable indication of power ratings for through-hole resistor products, as shown in figure 15 here.
The ideal solution is to develop sufficient understanding of the circuit to estimate the power dissipation requirement of the item, and choose accordingly. I don’t particularly care for the guess-and-try alternative, since telling the difference between an under-specified replacement and failing to correct the initial cause of the failure can be difficult.