AttributeErrors name suggestions when inside a property

There is a nice recent addition for python 3.13:

>>> class Foo:
...     def __init__(self, x):
...         self._x = x
... 
>>> Foo(1).x

The error message is AttributeError: 'Foo' object has no attribute 'x'. Did you mean: '_x'? in 3.12 and AttributeError: 'Foo' object has no attribute 'x'. in 3.13.0b3.

However, in my case, the attribute x really exists:

>>> class Foo:
...     def __init__(self, x: int):
...         self._x = x
... 
...     @property
...     def x(self):
...         # some code here that leads to x not being available
...         x_not_available = True
...         if x_not_available:
...             raise AttributeError("x is not available.")
...         return self._x
...         
>>> Foo(1).x
Traceback (most recent call last):
  File "<python-input-2>", line 1, in <module>
    Foo(1).x
  File "<python-input-1>", line 10, in x
    raise AttributeError("x is not available.")
AttributeError: x is not available.. Did you mean: '_x'?

In 3.12 and lower, there is a simple workaround: a subclass of AttributeError does not have these name suggestions. However, this is not the case in 3.13.0b3. What should I do? Perhaps an AttributeError exception is not appropriate here?

I’d just use a custom Exception subclass.