<commit_before># rubocop:disable all
class DropDataGridIndicesTables < ActiveRecord::Migration[5.1]
  include Marty::Migrations

  def up
    drop_table :marty_grid_index_booleans
    drop_table :marty_grid_index_int4ranges
    drop_table :marty_grid_index_integers
    drop_table :marty_grid_index_numranges
    drop_table :marty_grid_index_strings

    ActiveRecord::Base.connection.execute <<~SQL
      DROP FUNCTION IF EXISTS public.query_grid_dir;
      DROP FUNCTION IF EXISTS public.lookup_grid_distinct;
    SQL
  end
<commit_msg>Fix 606_drop_data_grid_indices_tables, so it would successfully drop the `query_grid_dir` and `lookup_grid_distinct` functions<commit_after># rubocop:disable all
class DropDataGridIndicesTables < ActiveRecord::Migration[5.1]
  include Marty::Migrations

  def up
    drop_table :marty_grid_index_booleans
    drop_table :marty_grid_index_int4ranges
    drop_table :marty_grid_index_integers
    drop_table :marty_grid_index_numranges
    drop_table :marty_grid_index_strings

    ActiveRecord::Base.connection.execute <<~SQL
      DROP FUNCTION IF EXISTS public.query_grid_dir(h jsonb, infos jsonb[], row_info jsonb);
      DROP FUNCTION IF EXISTS public.lookup_grid_distinct(h jsonb, row_info jsonb, return_grid_data boolean, dis boolean);
    SQL
  end

{'fraction_non_alphanumeric': 0.05723124516627997, 'fraction_numerical': 0.0069605568445475635, 'mean_word_length': 5.47, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3946739', 'n_tokens_mistral': 438, 'n_tokens_neox': 429, 'n_words': 91}