def METHOD_NAME(env):
    # this test reproduces crash where cardinality array was cleared on the GC
    env.skipOnCluster()
    conn = getConnectionByEnv(env)
    count = 100
    conn.execute_command('FT.CREATE', 'idx', 'SCHEMA', 'n', 'NUMERIC')
    for i in range(count):
        conn.execute_command('HSET', 'doc{}'.format(i), 'n', format(i))
    for i in range(count):
        conn.execute_command('DEL', 'doc{}'.format(i))
    forceInvokeGC(env, 'idx')
    for i in range(count):
        conn.execute_command('HSET', 'doc{}'.format(i), 'n', format(i))