@@ -265,8 +265,8 @@ def initialize_options(self):
265265 self ._parent .initialize_options (self )
266266
267267 # boolean
268- b_values = {0 , 1 , "1" , "0" , True , False }
269- t_values = {1 , "1" , True }
268+ b_values = {0 , 1 , "1" , "0" , True , False } # noqa: B033
269+ t_values = {1 , "1" , True } # noqa: B033
270270 for att in ["use_nvtx" , "use_cuda" , "manylinux" ]:
271271 v = getattr (self , att )
272272 if v is not None :
@@ -295,17 +295,17 @@ def initialize_options(self):
295295 def finalize_options (self ):
296296 self ._parent .finalize_options (self )
297297
298- b_values = {0 , 1 , "1" , "0" , True , False , "True" , "False" }
298+ b_values = {0 , 1 , "1" , "0" , True , False , "True" , "False" } # noqa: B033
299299 if self .use_nvtx not in b_values :
300300 raise ValueError (f"use_nvtx={ self .use_nvtx !r} must be in { b_values } ." )
301301 if self .use_cuda is None :
302302 self .use_cuda = find_cuda ()
303303 if self .use_cuda not in b_values :
304304 raise ValueError (f"use_cuda={ self .use_cuda !r} must be in { b_values } ." )
305305
306- self .use_nvtx = self .use_nvtx in {1 , "1" , True , "True" }
307- self .use_cuda = self .use_cuda in {1 , "1" , True , "True" }
308- self .manylinux = self .manylinux in {1 , "1" , True , "True" }
306+ self .use_nvtx = self .use_nvtx in {1 , "1" , True , "True" } # noqa: B033
307+ self .use_cuda = self .use_cuda in {1 , "1" , True , "True" } # noqa: B033
308+ self .manylinux = self .manylinux in {1 , "1" , True , "True" } # noqa: B033
309309
310310 if self .cuda_version in (None , "" ):
311311 self .cuda_version = None
@@ -599,7 +599,7 @@ def get_ext_modules():
599599 add_cuda = False
600600 elif "--use-cuda=0" in sys .argv :
601601 add_cuda = False
602- elif os .environ .get ("USE_CUDA" , None ) in {0 , "0" , False }:
602+ elif os .environ .get ("USE_CUDA" , None ) in {0 , "0" , False }: # noqa: B033
603603 add_cuda = False
604604 if add_cuda :
605605 cuda_extensions .extend ([])
0 commit comments