##// END OF EJS Templates
extension: check the command attributes using `sysstr`...
marmoute -
r51815:0e6cea0c default
parent child Browse files
Show More
@@ -165,7 +165,7 b' def _rejectunicode(name, xs):'
165 165
166 166
167 167 # attributes set by registrar.command
168 _cmdfuncattrs = (b'norepo', b'optionalrepo', b'inferrepo')
168 _cmdfuncattrs = ('norepo', 'optionalrepo', 'inferrepo')
169 169
170 170
171 171 def _validatecmdtable(ui, cmdtable):
@@ -175,10 +175,10 b' def _validatecmdtable(ui, cmdtable):'
175 175 missing = [a for a in _cmdfuncattrs if not util.safehasattr(f, a)]
176 176 if not missing:
177 177 continue
178 raise error.ProgrammingError(
179 b'missing attributes: %s' % b', '.join(missing),
180 hint=b"use @command decorator to register '%s'" % c,
181 )
178 msg = b'missing attributes: %s'
179 msg %= b', '.join([stringutil.forcebytestr(m) for m in missing])
180 hint = b"use @command decorator to register '%s'" % c
181 raise error.ProgrammingError(msg, hint=hint)
182 182
183 183
184 184 def _validatetables(ui, mod):
General Comments 0
You need to be logged in to leave comments. Login now