@@ -670,9 +670,9 @@ def update_variable(
670670 variable_library : str | UUID ,
671671 name : str ,
672672 new_name : Optional [str ] = None ,
673- new_type : Literal ["Boolean" , "DateTime" , "Number" , "Integer" , "String" ] = None ,
674- new_value : Optional [str ] = None ,
675- new_note : Optional [str ] = None ,
673+ type : Literal ["Boolean" , "DateTime" , "Number" , "Integer" , "String" ] = None ,
674+ value : Optional [str ] = None ,
675+ note : Optional [str ] = None ,
676676 workspace : Optional [str | UUID ] = None ,
677677):
678678 """
@@ -687,13 +687,13 @@ def update_variable(
687687 name : str
688688 Name of the variable.
689689 new_name : str, default=None
690- New name of the variable.
691- new_type : Literal["Boolean", "DateTime", "Number", "Integer", "String"], default=None
692- New type of the variable. Valid types are: "Boolean", "DateTime", "Number", "Integer", "String".
693- new_value : str, default=None
694- New value of the variable.
695- new_note : str, default=None
696- New note of the variable.
690+ New name of the variable. Defaults to None which keeps the same name.
691+ type : Literal["Boolean", "DateTime", "Number", "Integer", "String"], default=None
692+ New type of the variable. Valid types are: "Boolean", "DateTime", "Number", "Integer", "String". Defaults to None which keeps the same type.
693+ value : str, default=None
694+ New value of the variable. Defaults to None which keeps the same value.
695+ note : str, default=None
696+ New note of the variable. Defaults to None which keeps the same note.
697697 workspace : str | uuid.UUID, default=None
698698 The Fabric workspace name or ID.
699699 Defaults to None which resolves to the workspace of the attached lakehouse
@@ -712,7 +712,7 @@ def update_variable(
712712 return_dataframe = False ,
713713 )
714714
715- if new_name is None and new_type is None and new_value is None and new_note is None :
715+ if new_name is None and type is None and value is None and note is None :
716716 print (
717717 f"{ icons .info } No updates provided for the variable '{ name } ' in the '{ item_name } ' variable library within the '{ workspace_name } ' workspace."
718718 )
@@ -733,12 +733,12 @@ def update_variable(
733733 if variable .get ("name" ) == name :
734734 if new_name is not None :
735735 variable ["name" ] = new_name
736- if new_type is not None :
737- variable ["type" ] = new_type
738- if new_note is not None :
739- variable ["note" ] = new_note
740- if new_value is not None :
741- variable ["value" ] = new_value
736+ if type is not None :
737+ variable ["type" ] = type
738+ if note is not None :
739+ variable ["note" ] = note
740+ if value is not None :
741+ variable ["value" ] = value
742742 break
743743 part ["payload" ] = _encode_b64 (payload )
744744
0 commit comments