Can't seem to override orm constraint mapping
tl;dr
Overriding config/validation/orm.xml into my custom bundle (as talked about here http://symfony.com/doc/master/cookbook/bundles/inheritance.html#overriding-resources-templates-routing-validation-etc) doesn't seem to work.
I need to set a custom repositoryMethod for the UniqueEntity constraint on the emailCanonical field (https://github.com/FriendsOfSymfony/FOSUserBundle/blob/master/Resources/config/validation/orm.xml#L18). The easiest way to do this I thought was to override the validation file as described in the tl;dr above. However, doing so doesn't seem to work.
I can override the file config/validation.xml and indeed add my custom constraint mapping within this, however because of the ValidationCompilerPass it does not replace the constraint within config/validation/orm.xml but just adds another. Disabling the compiler pass within the FOSUserBundle makes it do what I want.
Is the ValidationPass stopping these files from being overridden or should I be trying to override this constraint in a different manner?
It's a framework limitation: symfony/symfony#3224
Thanks @mvrhov that is exactly the problem I'm encountering. Have got around it with validation groups but it isn't ideal.