Extension build error with Cython-3.0.0b3

When building with Cython-3, I'm getting the following error:

[1/4] Cythonizing src/zeroconf/_cache.py
warning: src/zeroconf/_cache.py:48:23: Unknown type declaration '_DNSRecordCacheType' in annotation, ignoring
warning: src/zeroconf/_cache.py:48:49: Unknown type declaration '_str' in annotation, ignoring
warning: src/zeroconf/_cache.py:48:63: Unknown type declaration '_DNSRecord' in annotation, ignoring
warning: src/zeroconf/_cache.py:68:33: Unknown type declaration '_DNSRecord' in annotation, ignoring
warning: src/zeroconf/_cache.py:101:36: Unknown type declaration '_DNSRecord' in annotation, ignoring
warning: src/zeroconf/_cache.py:147:42: Unknown type declaration '_str' in annotation, ignoring
warning: src/zeroconf/_cache.py:247:93: Unknown type declaration '_float' in annotation, ignoring
warning: src/zeroconf/_cache.py:261:32: Unknown type declaration '_DNSRecord' in annotation, ignoring
warning: src/zeroconf/_cache.py:261:49: Unknown type declaration '_str' in annotation, ignoring

Error compiling Cython file:
------------------------------------------------------------
...
        This function is not thread-safe and must be called from
        the event loop.
        """
        return self._async_all_by_details(name, type_, class_)

    def _async_all_by_details(self, name: _str, type_: int, class_: int) -> List[DNSRecord]:
    ^
------------------------------------------------------------

src/zeroconf/_cache.py:147:4: Signature not compatible with previous declaration

Error compiling Cython file:
------------------------------------------------------------
...

    @cython.locals(
        records=cython.dict,
        record=DNSRecord,
    )
    cdef _async_all_by_details(self, object name, object type_, object class_)
                              ^
------------------------------------------------------------

src/zeroconf/_cache.pxd:30:30: Previous declaration is here

Error compiling Cython file:
------------------------------------------------------------
...
                if (now - record.created > _ONE_SECOND) and record not in answers_rrset:
                    # Expire in 1s
                    record.set_created_ttl(now, 1)


def _dns_record_matches(record: _DNSRecord, key: _str, type_: int, class_: int) -> bool:
^
------------------------------------------------------------

src/zeroconf/_cache.py:261:0: Function signature does not match previous declaration

To reproduce, e.g. in a venv:

pip install --pre cython build poetry-core setuptools wheel
python -m build -nw