Skip to content

Regression: custom types seem to be overridden since 4.3.0 #7144

@BenMorel

Description

@BenMorel

Bug Report

Q A
Version 4.3.*
Previous Version if the bug is a regression 4.2.*

Summary

Since DBAL 4.3.0, the test suite for brick/geo-doctrine started failing:
https://github.com/brick/geo-doctrine/actions/runs/17490924621/job/49680343915

Doctrine\DBAL\Exception\InvalidColumnDeclaration: Column "geometry" has invalid type
...
Doctrine\DBAL\Exception\InvalidColumnType\ColumnLengthRequired: Doctrine\DBAL\Platforms\MySQL80Platform requires the length of a VARBINARY column to be specified

Types are added this way:

use Doctrine\DBAL\Types\Type;

Type::addType('Geometry', Types\GeometryType::class);

And used as:

#[ORM\Column(type: 'Geometry')]
public Geometry $geometry;

It looks like since version 4.3.0, the GeometryType is overridden at some point with BinaryType.

git bisect tells me that the culprit is a07b35c.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions