acoustic-carpenter-78188
04/07/2026, 8:59 PMconfig_fingerprint method ensures that only deployment-relevant configuration fields are included in the version hash, excluding non-deterministic fields such as lifecycle callbacks or objects with memory addresses. This prevents unnecessary version changes when redeploying identical configurations and improves reproducibility. The pull request also updates the version hashing logic to use these fingerprints and adds comprehensive tests to validate the new behavior.
Core improvements:
Deterministic fingerprinting for environments:
• Added a config_fingerprint method to the Environment base class and its subclasses, which produces a stable, deterministic string representing only deployment-relevant configuration fields, skipping fields with memory addresses or those explicitly excluded [1] [2].
• Subclasses such as AppEnvironment extend the set of excluded fields (e.g., lifecycle callbacks) to further ensure determinism.
Deployment and serving version computation:
• Updated version hashing in deployment and serving logic to use the new config_fingerprint instead of serializing the entire environment with cloudpickle, and to serialize the image cache in a deterministic way [1] [2].
Test coverage:
• Added extensive tests for the new fingerprinting logic, including determinism, sensitivity to config changes, and proper exclusion of non-deterministic fields, both in core and app environments [1] [2] [3].
Code cleanup:
• Removed unused cloudpickle imports from affected modules [1] [2].
• Removed a debug print statement from container_cmd.
flyteorg/flyte-sdkacoustic-carpenter-78188
04/08/2026, 3:21 AM