pearu / f2py

Automatically exported from code.google.com/p/f2py
Other
55 stars 39 forks source link

Fixes and Python 3 port #46

Closed inducer closed 6 years ago

inducer commented 6 years ago

Thanks for taking a look. We did encounter an issue (incorrectly parsed code, specifically, old parsing results being returned) when the id value matched a prior one. This code seems to use .id as a cache key, which somewhat supports that. Having to hunt that explained the angry commit message. (Sorry!)

pearu commented 6 years ago

Good point. hashlib.md5(string).hexdigest() ought to give a more robust solution, although there is a theoretical chance of the encountered issue reappearing. Let's keep your solution for correctness and where id is used only for visual, use its hash value.