And waits for them. That's pointless.
const ASTPtr &, const StorageMetadataPtr &, ContextPtr query_context, TableExclusiveLockHolder & table_lock)
{
    table_lock.release();   
    assertNotReadonly();
    if (!is_leader)
        throw Exception("TRUNCATE cannot be done on this replica because it is not a leader", ErrorCodes::NOT_A_LEADER);
    zkutil::ZooKeeperPtr zookeeper = getZooKeeper();
    Strings partitions = zookeeper->getChildren(fs::path(zookeeper_path) / "block_numbers");
    for (String & partition_id : partitions)
    {
        LogEntry entry;
        if (dropAllPartsInPartition(*zookeeper, partition_id, entry, query_context, false))
            waitForAllReplicasToProcessLogEntry(entry);
    }
}
PartitionCommandsResultInfo StorageReplicatedMergeTree::attachPartition(