summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGES.txt5
-rw-r--r--pyramid/renderers.py2
2 files changed, 4 insertions, 3 deletions
diff --git a/CHANGES.txt b/CHANGES.txt
index 104ed1e98..4e6feb68c 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -4,8 +4,9 @@ Next release
Bug Fixes
---------
-- It is now possible to use asset specifications which contain a hyphen in
- Mako asset spec names. See https://github.com/Pylons/pyramid/pull/692
+- When trying to determine Mako defnames and Chameleon macro names in asset
+ specifications, take into account that the filename may have a hyphen in
+ it. See https://github.com/Pylons/pyramid/pull/692
Features
--------
diff --git a/pyramid/renderers.py b/pyramid/renderers.py
index 3252c2c93..1368e190e 100644
--- a/pyramid/renderers.py
+++ b/pyramid/renderers.py
@@ -437,7 +437,7 @@ class ChameleonRendererLookup(object):
renderer = registry.queryUtility(ITemplateRenderer, name=spec)
if renderer is None:
p = re.compile(
- r'(?P<asset>[\w_.:/]+)'
+ r'(?P<asset>[\w_.:/-]+)'
r'(?:\#(?P<defname>[\w_]+))?'
r'(\.(?P<ext>.*))'
)