commands: document the "event_log" class attribute
Add some notes explaining why it's instantiated at the Command class
level and not individual objects.
Change-Id: Ib8081bb8480e85f6d3dfc23953c6bbc6ecc64934
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/309323
Reviewed-by: Raman Tenneti <rtenneti@google.com>
Tested-by: Mike Frysinger <vapier@google.com>
diff --git a/command.py b/command.py
index 8e93029..94f4d75 100644
--- a/command.py
+++ b/command.py
@@ -43,10 +43,15 @@
"""Base class for any command line action in repo.
"""
- event_log = EventLog()
manifest = None
_optparse = None
+ # Singleton for all commands to track overall repo command execution and
+ # provide event summary to callers. Only used by sync subcommand currently.
+ #
+ # NB: This is being replaced by git trace2 events. See git_trace2_event_log.
+ event_log = EventLog()
+
# Whether this command is a "common" one, i.e. whether the user would commonly
# use it or it's a more uncommon command. This is used by the help command to
# show short-vs-full summaries.