@@ -252,6 +252,14 @@ def test_memoizing_pickle_coder(self):
252252 param (compat_version = "2.68.0" ),
253253 ])
254254 def test_deterministic_coder (self , compat_version ):
255+ """ Test in process determinism for all special deterministic types
256+
257+ - In SDK version <= 2.67.0 dill is used to encode "special types"
258+ - In SDK version 2.68.0 cloudpickle is used to encode "special types" with
259+ absolute filepaths in code objects and dynamic functions.
260+ - In SDK version 2.69.0 cloudpickle is used to encode "special types" with
261+ relative filepaths in code objects and dynamic functions.
262+ """
255263
256264 typecoders .registry .update_compatibility_version = compat_version
257265 coder = coders .FastPrimitivesCoder ()
@@ -329,6 +337,15 @@ def test_deterministic_coder(self, compat_version):
329337 param (compat_version = "2.68.0" ),
330338 ])
331339 def test_deterministic_map_coder_is_update_compatible (self , compat_version ):
340+ """ Test in process determinism for map coder including when a component
341+ coder uses DeterministicFastPrimitivesCoder for "special types".
342+
343+ - In SDK version <= 2.67.0 dill is used to encode "special types"
344+ - In SDK version 2.68.0 cloudpickle is used to encode "special types" with
345+ absolute filepaths in code objects and dynamic functions.
346+ - In SDK version 2.69.0 cloudpickle is used to encode "special types" with
347+ relative file
348+ """
332349 typecoders .registry .update_compatibility_version = compat_version
333350 values = [{
334351 MyTypedNamedTuple (i , 'a' ): MyTypedNamedTuple ('a' , i )
@@ -688,7 +705,14 @@ def test_param_windowed_value_coder(self):
688705 ])
689706 def test_cross_process_encoding_of_special_types_is_deterministic (
690707 self , compat_version ):
691- """Test cross-process determinism for all special deterministic types"""
708+ """Test cross-process determinism for all special deterministic types
709+
710+ - In SDK version <= 2.67.0 dill is used to encode "special types"
711+ - In SDK version 2.68.0 cloudpickle is used to encode "special types" with
712+ absolute filepaths in code objects and dynamic functions.
713+ - In SDK version 2.69.0 cloudpickle is used to encode "special types" with
714+ relative filepaths in code objects and dynamic functions.
715+ """
692716 is_using_dill = compat_version == "2.67.0"
693717 if is_using_dill :
694718 pytest .importorskip ("dill" )
@@ -806,6 +830,8 @@ def run_subprocess():
806830 continue
807831
808832 if test_name == "named_tuple_simple" and not is_using_dill :
833+ # The absense of a compat_version means we are using the most recent
834+ # implementation of the coder, which uses relative paths.
809835 should_have_relative_path = not compat_version
810836 named_tuple_type = type (decoded1 )
811837 self .assertEqual (
0 commit comments