python-babel/flask-babel

`locked_cached_property` is deprecated as of Flask>=2.3.0

jkittner opened this issue · 1 comments

issue: pallets/flask#4993
pr: pallets/flask#4998

This is the only part where this is used. I'm wondering though, whether locking is even needed in this case or if a werkzeug.utils.cached_property is enough?

@locked_cached_property
def domain_instance(self):
"""The message domain for the translations.
"""
return Domain(domain=self.domain)

happy to send a PR swapping the decorator. But just wanted to be sure whether the lock is actually needed.
(tests pass with werkzeug.utils.cached_property)

TkTech commented

This change would be accepted. I don't believe the locking is necessary here and is a legacy of the pre-app-specific configuration.