parameters: (project_id:Union[int, str], user_id, op_type:str, location=None, freetext=None)
return_statement: return None
docstring: Inserts a new entry into the log table. If the location parameter is
      passed, it is expected to be an iteratable (list, tuple).
docstring_summary: Inserts a new entry into the log table. If the location parameter is
      passed, it is expected to be an iteratable (list, tuple).
docstring_tokens: Inserts a new entry into the log table . If the location parameter is passed it is expected to be an iteratable ( list tuple ) .
function: def insert_into_log(project_id:Union[int, str], user_id, op_type:str, location=None, freetext=None) -> Optional[Dict[str, str]]:
      """ Inserts a new entry into the log table. If the location parameter is
      passed, it is expected to be an iteratable (list, tuple).
      """
      # valid operation types
      operation_type_array = [
          "rename_root",
          "create_neuron",
          "rename_neuron",
          "remove_neuron",
          "move_neuron",
  
          "create_group",
          "rename_group",
          "remove_group",
          "move_group",
  
          "create_skeleton",
          "rename_skeleton",
          "remove_skeleton",
          "move_skeleton",
  
          "split_skeleton",
          "join_skeleton",
          "reroot_skeleton",
  
          "change_confidence",
  
          "reset_reviews"
      ]
  
      if op_type not in operation_type_array:
          raise ValueError(f'Operation type {op_type} not valid')
  
      new_log = Log()
      new_log.user_id = user_id
      new_log.project_id = project_id
      new_log.operation_type = op_type
      if location is not None:
          new_log.location = Double3D(*location)
      if freetext is not None:
          new_log.freetext = freetext
  
      new_log.save()
      return None
function_tokens: def insert_into_log ( project_id : Union [ int , str ] , user_id , op_type : str , location = None , freetext = None ) -> Optional [ Dict [ str , str ] ] : # valid operation types operation_type_array = [ "rename_root" , "create_neuron" , "rename_neuron" , "remove_neuron" , "move_neuron" , "create_group" , "rename_group" , "remove_group" , "move_group" , "create_skeleton" , "rename_skeleton" , "remove_skeleton" , "move_skeleton" , "split_skeleton" , "join_skeleton" , "reroot_skeleton" , "change_confidence" , "reset_reviews" ] if op_type not in operation_type_array : raise ValueError ( f'Operation type {op_type} not valid' ) new_log = Log ( ) new_log . user_id = user_id new_log . project_id = project_id new_log . operation_type = op_type if location is not None : new_log . location = Double3D ( * location ) if freetext is not None : new_log . freetext = freetext new_log . save ( ) return None