(you don't have to strictly follow this form)

**Describe the bug**
A link to the report: https://s3.amazonaws.com/clickhouse-test-reports/35466/d81c58b5d9be45ac69c3859b5cbe97080711f6d9/fuzzer_astfuzzerubsan,actions//report.html
The commit: https://github.com/ClickHouse/ClickHouse/commit/d81c58b5d9be45ac69c3859b5cbe97080711f6d9
{
    BlockIO res;
    QueryPlan query_plan;
    buildQueryPlan(query_plan);
    res.pipeline = QueryPipelineBuilder::getPipeline(std::move(*query_plan.buildQueryPipeline(
        QueryPlanOptimizationSettings::fromContext(context), BuildQueryPipelineSettings::fromContext(context))));
    return res;
}
Block InterpreterSelectQuery::getSampleBlockImpl()
{
    query_info.query = query_ptr;
    query_info.has_window = query_analyzer->hasWindow();
    if (storage && !options.only_analyze)
    {
        auto & query = getSelectQuery();
        query_analyzer->makeSetsForIndex(query.where());
        query_analyzer->makeSetsForIndex(query.prewhere());
        query_info.sets = query_analyzer->getPreparedSets();
        from_stage = storage->getQueryProcessingStage(context, options.to_stage, storage_snapshot, query_info);
    }
    
    
    
    
    
    
    bool first_stage = from_stage < QueryProcessingStage::WithMergeableState
        && options.to_stage >= QueryProcessingStage::WithMergeableState;