code: def is_blocked_time_series(
      df: pd.DataFrame, date_col: str, search_keys: List[str]
  ) -> bool:
      df = df.copy()
      seconds = "datetime_seconds"
      df[date_col] = pd.to_datetime(df[date_col])
      df[date_col] = df[date_col].dt.tz_localize(None)
      df[seconds] = (
          df[date_col] - df[date_col].dt.floor("D")
      ).dt.seconds
  
      seconds_without_na = df[seconds].dropna()
      columns_to_drop = [c for c in search_keys if c != date_col] + [
          seconds
      ]
      df.drop(columns=columns_to_drop, inplace=True)
      # Date, not datetime
      if (
          seconds_without_na != 0
      ).any() and seconds_without_na.nunique() > 1:
          return False
  
      nunique_dates = df[date_col].nunique()
      # Unique dates count more than 270
      if nunique_dates < 270:
          return False
  
      min_date = df[date_col].min()
      max_date = df[date_col].max()
      days_delta = (max_date - min_date).days + 1
      # Missing dates less than 30% (unique dates count and days delta between earliest and latest dates)
      if nunique_dates / days_delta < 0.3:
          return False
  
      def check_differences(group):
          data = group.drop(date_col, axis=1)
          diffs = data.values[:, None] != data.values
          diff_counts = diffs.sum(axis=2)
          max_diff = np.max(diff_counts)
          return max_diff <= 2
  
      def is_multiple_rows(group):
          return group.shape[0] > 1
  
      grouped = df.groupby(date_col)
      dates_with_multiple_rows = len(grouped.apply(is_multiple_rows))
  
      # share of dates with more than one record is more than 99%
      if dates_with_multiple_rows / nunique_dates < 0.99:
          return False
  
      if df.shape[1] <= 3:
          return True
  
      is_diff_less_than_two_columns = grouped.apply(check_differences)
      return is_diff_less_than_two_columns.all()
  
file_path: upgini/src/upgini/utils/datetime_utils.py
imports: import datetime
  import logging
  import re
  from typing import List, Optional
  import numpy
  import pandas
  from dateutil.relativedelta import relativedelta
  from pandas.api.types import is_numeric_dtype, is_period_dtype, is_string_dtype
  from upgini.errors import ValidationError
label_desc: Use image node_id 2 for calling a global function with example usage: is_blocked_time_series(df, date_col, search_keys) and returns: is_diff_less_than_two_columns, False, False, False, unknown, unknown, False, True