A generic MQTT example can be misleading on a broker with different retained-message behavior. Adafruit IO's MQTT documentation describes requesting the latest feed value through a /get topic rather than relying on the PUBLISH retain flag.
For the Adafruit IO integration, restart a test subscriber after publishing a harmless value. Follow the documented retrieval path and distinguish that historical value from a newly arriving measurement.