One chemical sometimes mentioned is chlorfenuron, a plant growth regulator that can speed up fruit growth. While it may contribute to unusual textures in some cases, rules about its use vary by country, and the health effects of typical exposure are still not fully clear.
The best approach is to judge the fruit carefully. A good watermelon should feel heavy for its size, have a firm rind, a creamy yellow spot, and smell fresh and sweet after cutting.
Small internal cracks are usually not a problem if the watermelon looks, smells, and tastes normal. But if it has a bad odor, slimy texture, mold, fermented taste, or widespread spoilage, it should be thrown away.