Commit 84dc28ae authored by Jérome Perrin's avatar Jérome Perrin

info: don't output last_tid when output all parameters

so that the "W: last_tid is deprecated alias for head" warning is not
displayed.
parent cdfd5a52
......@@ -34,6 +34,8 @@ infoDict = OrderedDict([
("name", lambda stor: stor.getName()),
("size", lambda stor: stor.getSize()),
("head", lambda stor: ashex(stor.lastTransaction())),
])
deprecatedInfoDict = OrderedDict([
("last_tid", _last_tid),
])
......@@ -44,7 +46,7 @@ def zodbinfo(stor, parameterv):
wantnames = True
for parameter in parameterv:
get_parameter = infoDict.get(parameter)
get_parameter = infoDict.get(parameter, deprecatedInfoDict.get(parameter))
if get_parameter is None:
print("invalid parameter: %s" % parameter, file=sys.stderr)
sys.exit(1)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment