Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit eec34b1

Browse files
authored
Work around Mjolnir compatibility issue by adding an import for glob_to_regex in synapse.util, where it moved from. (#11696)
1 parent daea7bc commit eec34b1

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

changelog.d/11696.misc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Work around Mjolnir compatibility issue by adding an import for `glob_to_regex` in `synapse.util`, where it moved from.

synapse/util/__init__.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,13 @@
3131
if typing.TYPE_CHECKING:
3232
pass
3333

34+
# FIXME Mjolnir imports glob_to_regex from this file, but it was moved to
35+
# matrix_common.
36+
# As a temporary workaround, we import glob_to_regex here for
37+
# compatibility with current versions of Mjolnir.
38+
# See https://github.com/matrix-org/mjolnir/pull/174
39+
from matrix_common.regex import glob_to_regex # noqa
40+
3441
logger = logging.getLogger(__name__)
3542

3643

0 commit comments

Comments
 (0)