[Checkins]
SVN: martian/branches/philikon-decl-dir-rules/src/martian/directive.py
Another sanity check.
Martijn Faassen
faassen at infrae.com
Mon May 5 09:01:29 EDT 2008
Log message for revision 86449:
Another sanity check.
Changed:
U martian/branches/philikon-decl-dir-rules/src/martian/directive.py
-=-
Modified: martian/branches/philikon-decl-dir-rules/src/martian/directive.py
===================================================================
--- martian/branches/philikon-decl-dir-rules/src/martian/directive.py 2008-05-05 12:57:48 UTC (rev 86448)
+++ martian/branches/philikon-decl-dir-rules/src/martian/directive.py 2008-05-05 13:01:28 UTC (rev 86449)
@@ -186,6 +186,10 @@
"The directive '%s' has scope CLASS_OR_MODULE "
"but no module was passed in to ``get``" %
self.directive.__name__)
+ if directive.scope is CLASS and module is not None:
+ raise TypeError(
+ "The directive '%s' has scope CLASS "
+ "but a module was also passed into ``get``")
value = directive.store.get(directive, component, default=_USE_DEFAULT)
if value is _USE_DEFAULT and module is not None:
value = directive.store.get(directive, module, default=_USE_DEFAULT)
More information about the Checkins
mailing list