This is inaccurate in two ways.
First, only keyboards and those playing with them, use a fixed temperament. Everyone else, strings, voices, brass, winds, adjusts the pitch of individual notes based on vertical and horizontal context. A c does not have a fixed number of Hz throughout a piece.
Second, math did not provide the ultimate compromise. Equal temperament was known as far back as the fourth century BC, and people were advocating for and composing in equal temperament in the sixteenth century. Rejecting equal temperament in favor of meantone temperings was a conscious decision, not a compromise from ignorance.
There is a reference here however to a chinese mathematician who worked it out in 1584. I don't know if his work made it across the continent and influenced anyone. It is not likely that many musicians would have understood the math in the 16th century.
https://en.wikipedia.org/wiki/Well_temperament#targetText=Or....
A klavier is not necessarily a clavichord, but an organ has some interesting tuning tricks up its sleeves with its various stops.
Organs are tuned directly at the individual pipes (just like string instruments are tuned at the strings). Each pipe, depending on the kind of pipe used has a slide that goes in and out on one end to match the pipe length or, alternatively, a tiny tongue of metal that is rolled up or extended. Tuning (or 'voicing') an organ is super labor intensive and time consuming.
For a large organ it can take weeks.
The problem is, once you construct a diatonic scale using these "Pythagorean" ratios, trying to play a diatonic scale that starts and ends on a different pitch, but using the same set of pitches, will have intervals that aren't in tune and sound terrible.
Musicians and theorists struggled with this for years, coming up with various compromises that sounded good in some "keys" and awful in others, until math provided the ultimate compromise: base your logarithmic scale on twelfth roots of two and every key will be exactly the same more-or-less-in-tune.