Alchemist tried to discover how to get an immortal life, but reached the opposite

In China was an alchemist that was trying to discover an elixer of life that would render the person immortal. This experiment failed, and had quite the opposite effect! It had no immortal effects on the person, the opposite; it would explode with a flash and a bang if exposed to fire. You’re right: this person discovered gunpowder!