Undo potentially confusing name change in packaging.

This method was named reinitialize_command in distutils and accompanied
by a comment suggesting to change it to get_reinitialized_command.
Following that, I did the change for distutils2, but it proved
confusing: The Distribution object has an internal cache of command
objects, to make sure only one instance is ever used, and the name
get_reinitialized_command could suggest that the object returned was
independent of that cache, which it was not.  I’m reverting the name
change to make code clearer.
This commit is contained in:
Éric Araujo 2011-11-06 06:54:05 +01:00
parent 4e377f215d
commit a963e0d917
8 changed files with 19 additions and 19 deletions

View file

@ -318,8 +318,8 @@ class Command:
cmd_obj.ensure_finalized()
return cmd_obj
def get_reinitialized_command(self, command, reinit_subcommands=False):
return self.distribution.get_reinitialized_command(
def reinitialize_command(self, command, reinit_subcommands=False):
return self.distribution.reinitialize_command(
command, reinit_subcommands)
def run_command(self, command):