A workaround would be to add an extra parameter to height-constrained images, such as 623px-heightconstrained-Foo.png (as far as I can see, this is a non-scary change), and not purge files which have this parameter. A bit messy, but if the purging itself is also a temporary workaround until we have a new storage mechanism with proper usage-based cache eviction, there is no point messing with fundamentals of the thumbnail url syntax.