Skip to content

Do not differentiate integer/float identifier types #766

Open
@jmikola

Description

@jmikola

See #444 (comment):

Don't differentiate between integers and floats (see aa168b1), which will make this consistent with MongoDB's comparison behavior

Beyond that, the only caveat I see is that searching by an integer/float will not find a numeric string, and vice versa. This is evident in the IdTest fix made in aa168b1#L2L84 -- it may bite some users, but I think it's necessary unless we want to seriously complicate the IdType class.

MongoDB considers integers and float types equivalent for purposes of matching and indexing (including uniqueness). We should do the same in UnitOfWork's identity map.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions