@@ -1111,7 +1111,8 @@ def compute_hash(self) -> str:
11111111 factors : list [Any ] = []
11121112 factors .append (self .cache_dtype )
11131113 # `cpu_offload_gb` does not use `torch.compile` yet.
1114- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
1114+ hash_str = hashlib .md5 (str (factors ).encode (),
1115+ usedforsecurity = False ).hexdigest ()
11151116 return hash_str
11161117
11171118 def __init__ (
@@ -1243,7 +1244,8 @@ def compute_hash(self) -> str:
12431244 # no factors to consider.
12441245 # this config will not affect the computation graph.
12451246 factors : list [Any ] = []
1246- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
1247+ hash_str = hashlib .md5 (str (factors ).encode (),
1248+ usedforsecurity = False ).hexdigest ()
12471249 return hash_str
12481250
12491251 def __post_init__ (self ):
@@ -1354,7 +1356,8 @@ def compute_hash(self) -> str:
13541356 # no factors to consider.
13551357 # this config will not affect the computation graph.
13561358 factors : list [Any ] = []
1357- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
1359+ hash_str = hashlib .md5 (str (factors ).encode (),
1360+ usedforsecurity = False ).hexdigest ()
13581361 return hash_str
13591362
13601363 def __post_init__ (self ):
@@ -1674,7 +1677,8 @@ def compute_hash(self) -> str:
16741677 # no factors to consider.
16751678 # this config will not affect the computation graph.
16761679 factors : list [Any ] = []
1677- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
1680+ hash_str = hashlib .md5 (str (factors ).encode (),
1681+ usedforsecurity = False ).hexdigest ()
16781682 return hash_str
16791683
16801684 def __post_init__ (self ) -> None :
@@ -1810,7 +1814,8 @@ def compute_hash(self) -> str:
18101814 # the device/platform information will be summarized
18111815 # by torch/vllm automatically.
18121816 factors : list [Any ] = []
1813- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
1817+ hash_str = hashlib .md5 (str (factors ).encode (),
1818+ usedforsecurity = False ).hexdigest ()
18141819 return hash_str
18151820
18161821 def __init__ (self , device : str = "auto" ) -> None :
@@ -1983,7 +1988,8 @@ def compute_hash(self) -> str:
19831988 # no factors to consider.
19841989 # spec decode does not use `torch.compile` yet.
19851990 factors : list [Any ] = []
1986- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
1991+ hash_str = hashlib .md5 (str (factors ).encode (),
1992+ usedforsecurity = False ).hexdigest ()
19871993 return hash_str
19881994
19891995 @classmethod
@@ -2358,7 +2364,8 @@ def compute_hash(self) -> str:
23582364 factors .append (self .lora_extra_vocab_size )
23592365 factors .append (self .long_lora_scaling_factors )
23602366 factors .append (self .bias_enabled )
2361- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
2367+ hash_str = hashlib .md5 (str (factors ).encode (),
2368+ usedforsecurity = False ).hexdigest ()
23622369 return hash_str
23632370
23642371 def __post_init__ (self ):
@@ -2424,7 +2431,8 @@ def compute_hash(self) -> str:
24242431 # no factors to consider.
24252432 # this config will not affect the computation graph.
24262433 factors : list [Any ] = []
2427- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
2434+ hash_str = hashlib .md5 (str (factors ).encode (),
2435+ usedforsecurity = False ).hexdigest ()
24282436 return hash_str
24292437
24302438 def __post_init__ (self ):
@@ -2469,7 +2477,8 @@ def compute_hash(self) -> str:
24692477 # no factors to consider.
24702478 # this config will not affect the computation graph.
24712479 factors : list [Any ] = []
2472- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
2480+ hash_str = hashlib .md5 (str (factors ).encode (),
2481+ usedforsecurity = False ).hexdigest ()
24732482 return hash_str
24742483
24752484 def get_limit_per_prompt (self , modality : str ) -> int :
@@ -2535,7 +2544,8 @@ def compute_hash(self) -> str:
25352544 # no factors to consider.
25362545 # this config will not affect the computation graph.
25372546 factors : list [Any ] = []
2538- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
2547+ hash_str = hashlib .md5 (str (factors ).encode (),
2548+ usedforsecurity = False ).hexdigest ()
25392549 return hash_str
25402550
25412551 @staticmethod
@@ -2816,7 +2826,8 @@ def compute_hash(self) -> str:
28162826 # no factors to consider.
28172827 # this config will not affect the computation graph.
28182828 factors : list [Any ] = []
2819- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
2829+ hash_str = hashlib .md5 (str (factors ).encode (),
2830+ usedforsecurity = False ).hexdigest ()
28202831 return hash_str
28212832
28222833 def __post_init__ (self ):
@@ -2866,7 +2877,8 @@ def compute_hash(self) -> str:
28662877 # no factors to consider.
28672878 # this config will not affect the computation graph.
28682879 factors : list [Any ] = []
2869- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
2880+ hash_str = hashlib .md5 (str (factors ).encode (),
2881+ usedforsecurity = False ).hexdigest ()
28702882 return hash_str
28712883
28722884 def __post_init__ (self ):
@@ -2928,7 +2940,8 @@ def compute_hash(self) -> str:
29282940 # no factors to consider.
29292941 # this config will not affect the computation graph.
29302942 factors : list [Any ] = []
2931- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()
2943+ hash_str = hashlib .md5 (str (factors ).encode (),
2944+ usedforsecurity = False ).hexdigest ()
29322945 return hash_str
29332946
29342947 @classmethod
@@ -3425,7 +3438,8 @@ def compute_hash(self) -> str:
34253438 vllm_factors .append ("None" )
34263439 factors .append (vllm_factors )
34273440
3428- hash_str = hashlib .md5 (str (factors ).encode ()).hexdigest ()[:10 ]
3441+ hash_str = hashlib .md5 (str (factors ).encode (),
3442+ usedforsecurity = False ).hexdigest ()[:10 ]
34293443 return hash_str
34303444
34313445 def pad_for_cudagraph (self , batch_size : int ) -> int :
0 commit comments