3 ms·
It also has application-specific magic hidden deep in the source. Example: https://github.com/docker-slim/docker-slim/blob/master/internal/app/sensor/artifacts.
by peterwwillis 7y ago
It also has application-specific magic hidden deep in the source. Example: https://github.com/docker-slim/docker-slim/blob/master/internal/app/sensor/artifacts.go https://github.com/docker-slim/docker-slim/blob/master/inter...
- kortex 7y agohttps://github.com/docker-slim/docker-slim/blob/master/internal/app/sensor/artifacts.go#L570 https://github.com/docker-slim/docker-slim/blob/master/inter... func fixPy3CacheFile(src, dst string) error { ...} Yeahhh, that is your classic example of "things you definitely DO want an explanation comment for"
- kylequest 7y agoDifferent application runtimes have interesting hidden behaviors. With Python, for example, the runtime will generate cache files from your .py files and then it'll use it instead of those .py file. However, it still checks if the original source code is still there. If it's not there the runtime will refuse to use the cache files.