Skip to content

Commit bab802e

Browse files
committed
fix(web): locked_cached_property import error
Fix flask.helpers locked_cached_property import error that has been removed in recent versions of Flask. The upstream changed is tracked in this PR: pallets/flask#4998 According to Flask upstream developers, the right solution is to used cached_property from werkzeug.utils instead. fix #190
1 parent 3b6870f commit bab802e

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

CHANGELOG.md

+2
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
259259
- Drop off artifact and sources archives tarballs in subdirectory of fatbuildr
260260
runtime directory to avoid potential collisions between multiple builds in
261261
queue (#179).
262+
- Fix `flask.helpers` `locked_cached_property` import error in recent versions
263+
of Flask (#190).
262264
- docs:
263265
- Add missing path parameter in REST API to retrieve artifact information.
264266
- Add missing optional `architectures` parameter in instances pipelines

fatbuildr/protocols/http/server/__init__.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
from pathlib import Path
2222

2323
from flask import Flask
24-
from flask.helpers import locked_cached_property
24+
from werkzeug.utils import cached_property
2525
from jinja2 import FileSystemLoader
2626

2727
from . import views
@@ -219,7 +219,7 @@ def run(self):
219219
debug=self.conf.run.debug,
220220
)
221221

222-
@locked_cached_property
222+
@cached_property
223223
def jinja_loader(self):
224224
"""Override Flask Scaffold.jinja_loader() to use Jinja2
225225
FileSystemLoader with 2 paths: the site templates directory and the

0 commit comments

Comments
 (0)