This is an archive of the discontinued Mercurial Phabricator instance.

templateutil: fix a missing ABCMeta assignment
ClosedPublic

Authored by durin42 on Nov 6 2019, 5:55 PM.

Details

Summary

Caught by pytype.

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

durin42 created this revision.Nov 6 2019, 5:55 PM
indygreg accepted this revision.Nov 7 2019, 3:04 AM
This revision is now accepted and ready to land.Nov 7 2019, 3:04 AM
dlax added a subscriber: dlax.Nov 7 2019, 3:21 AM
dlax added inline comments.
mercurial/templateutil.py
114

This is ignored on Python 3 (meaning it's possible to instantiate mappable directly, despite some methods being abstract). It should be class mappable(metaclass=abc.ABCMeta) on Python 3.
But I realize that there are other __metaclass__ = abc.ABCMeta in the code base. Do we handle this somehow or has this been overlooked?

dlax added inline comments.Nov 7 2019, 3:26 AM
mercurial/templateutil.py
114

Just seen D7272 and others which explain this. Nevermind.

This revision was automatically updated to reflect the committed changes.