code: def unique_dict_in_list(array):
      """Returns the unique dictionaries in the input list,
      preserving the original order. Replaces ``unique_elements_in_list``
      because `dict` is not hashable.
  
      Parameters
      ----------
      array: `List` [`dict`]
          List of dictionaries.
  
      Returns
      -------
      unique_array : `List` [`dict`]
          Unique dictionaries in `array`, preserving the order of first appearance.
      """
      if not array:
          return array
      result = []
      # Brute force.
      # Avoids comparing json dumped ordered dictionary.
      # The reason is that when dictionary contains list/dict unhashable items, set does not work.
      for item in array:
          if not any([item == element for element in result]):
              result.append(item)
      return result
  
imports: import copy
  import dataclasses
  import functools
  import math
  import re
  import warnings
  from dataclasses import field
  from typing import List
  import numpy
  import pandas
  from pandas.testing import assert_frame_equal
  from pandas.testing import assert_index_equal
  from pandas.testing import assert_series_equal
label_desc: Use image node_id 4 for calling a global function with example usage: unique_dict_in_list(array) and returns: result, array