Got something like that in practice with backup recovery - IRL most probably the sequence of events leading to that discrepancy was different (not clear yet).

```sql
drop table enum_alter_issue;
create table enum_alter_issue (a Enum8('one' = 1, 'two' = 2)) engine = ReplicatedMergeTree('/clickhouse/tables/enum_alter_issue', 'test') ORDER BY a;

-- backup / move part aside or similar operation 
insert into enum_alter_issue values ('one'), ('two');
alter table enum_alter_issue detach partition id 'all';

-- schema evolution (enum get extended)
alter table enum_alter_issue modify column a Enum8('one' = 1, 'two' = 2, 'three' = 3);
insert into enum_alter_issue values ('one'), ('two');
alter table enum_alter_issue detach partition id 'all';

-- attempt to attach back all the parts (new generation and old generation)
alter table enum_alter_issue attach partition id 'all';

Received exception from server (version 21.9.1):
Code: 53. DB::Exception: Received from localhost:9000. DB::Exception: Type mismatch for column a. Column has type Enum8('one' = 1, 'two' = 2, 'three' = 3), got type Enum8('one' = 1, 'two' = 2). 
```
{
    if (column_names.empty())
    {
        auto list_of_columns = listOfColumns(getColumns().getAllPhysicalWithSubcolumns());
        throw Exception(ErrorCodes::EMPTY_LIST_OF_COLUMNS_QUERIED,
            "Empty list of columns queried. There are columns: {}", list_of_columns);
    }
    const auto virtuals_map = getColumnsMap(virtuals);
    UniqueStrings unique_names;
    for (const auto & name : column_names)
    {
        bool has_column = getColumns().hasColumnOrSubcolumn(ColumnsDescription::AllPhysical, name)
            || virtuals_map.find(name) != nullptr;
        if (!has_column)
        {
            auto list_of_columns = listOfColumns(getColumns().getAllPhysicalWithSubcolumns());
            throw Exception(ErrorCodes::NO_SUCH_COLUMN_IN_TABLE,
                "There is no column with name {} in table {}. There are columns: {}",
                backQuote(name), storage_id.getNameForLogs(), list_of_columns);
        }
        if (unique_names.end() != unique_names.find(name))
            throw Exception(ErrorCodes::COLUMN_QUERIED_MORE_THAN_ONCE, "Column {} queried more than once", name);
        unique_names.insert(name);
    }
}
void StorageInMemoryMetadata::check(const NamesAndTypesList & provided_columns) const