Hi all, I've renamed a bunch of modules to clean up after a mistake I made a long time ago. Fortunately, this also coincides with fixing things to come in line with the style guide better. I'd prefer we do this in SVN trunk, so that I don't miss any renames from applying a patch from hg=>SVN. This was done in r Modules that share a name with a class *have* to be renamed, otherwise the import mechanism breaks in a number of cases, and I'm not sure I can work around this. Here's my list: PlotCollection.py => plot_collection.py FieldInfoContainer.py => field_info_container.py ObjectFindingMixin.py => object_finding_mixing.py Britton, can you verify these are okay: Clump.py => clump.py HaloProfiler.py => halo_profiler.py EnzoSimulation.py => enzo_simulation.py LightCone*.py => light_cone_*.py Stephen, can you verify: MergerTree.py => merger_tree.py Keep in mind that all auto-generated documentation, as well as reliable selective imports, are broken when the module is the same name as the class. So we can rename one or the other... And I apologize that I didn't catch any of these sooner. But I'm about 75% done with docstrings for PlotCollection.py, and this was breaking auto-generation of the docs. Thanks, Matt
Matt,
Stephen, can you verify: MergerTree.py => merger_tree.py
I'm not entirely clear what I should be doing. Should I rename the file myself, and verify that any mention of the file name in other source files and docs is also changed? What about other things, like the HaloMassFcn.py file? Does that need to be renamed? _______________________________________________________ sskory@physics.ucsd.edu o__ Stephen Skory http://physics.ucsd.edu/~sskory/ _.>/ _Graduate Student ________________________________(_)_\(_)_______________
Hi Stephen,
I'm not entirely clear what I should be doing. Should I rename the file myself, and verify that any mention of the file name in other source files and docs is also changed?
That would be great, yes. In SVN would be best.
What about other things, like the HaloMassFcn.py file? Does that need to be renamed?
I missed that one, but yes, because it defines a class name the same as the object name, it should be renamed. Perhaps halo_mass_function.py. -Matt
Some of the files I've been assigned refer to things that Stephen will
probably change, such as HaloFinders -> halo_finders. I will change things
like this according to this convention. Maybe we should reply to this with
a list of files we changed, just to make sure we get all the imports right.
Britton
On Mon, Jun 7, 2010 at 8:04 PM, Matthew Turk
Hi Stephen,
I'm not entirely clear what I should be doing. Should I rename the file myself, and verify that any mention of the file name in other source files and docs is also changed?
That would be great, yes. In SVN would be best.
What about other things, like the HaloMassFcn.py file? Does that need to be renamed?
I missed that one, but yes, because it defines a class name the same as the object name, it should be renamed. Perhaps halo_mass_function.py.
-Matt _______________________________________________ Yt-dev mailing list Yt-dev@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
Britton,
Some of the files I've been assigned refer to things that Stephen will probably change, such as HaloFinders -> halo_finders. I will change things like this according to this convention. Maybe we should reply to this with a list of files we changed, just to make sure we get all the imports right.
I'm fine with you changing things in stuff I've written to correspond to changes you've just made. Is that what you did, anyway (I hope!)? _______________________________________________________ sskory@physics.ucsd.edu o__ Stephen Skory http://physics.ucsd.edu/~sskory/ _.>/ _Graduate Student ________________________________(_)_\(_)_______________
Matt has pointed out to me that the HaloFinding that I referenced did not
actually count, since that itself wasn't the Class. I am actually changing
my mind on this point anyway. We should probably just be in charge of
changing all import statements in all files when we do the file name
changing. That way we run a smaller risk of having broken imports for a
period of time.
Britton
On Mon, Jun 7, 2010 at 8:26 PM, Stephen Skory
Britton,
Some of the files I've been assigned refer to things that Stephen will probably change, such as HaloFinders -> halo_finders. I will change things like this according to this convention. Maybe we should reply to this with a list of files we changed, just to make sure we get all the imports right.
I'm fine with you changing things in stuff I've written to correspond to changes you've just made. Is that what you did, anyway (I hope!)?
_______________________________________________________ sskory@physics.ucsd.edu o__ Stephen Skory http://physics.ucsd.edu/~sskory/ http://physics.ucsd.edu/%7Esskory/ _.>/ _Graduate Student ________________________________(_)_\(_)_______________ _______________________________________________ Yt-dev mailing list Yt-dev@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
I agree, yes -- when you rename a module, it's fine to fix all the
other imports that reference that module.
-Matt
On Mon, Jun 7, 2010 at 2:36 PM, Britton Smith
Matt has pointed out to me that the HaloFinding that I referenced did not actually count, since that itself wasn't the Class. I am actually changing my mind on this point anyway. We should probably just be in charge of changing all import statements in all files when we do the file name changing. That way we run a smaller risk of having broken imports for a period of time.
Britton
On Mon, Jun 7, 2010 at 8:26 PM, Stephen Skory
wrote: Britton,
Some of the files I've been assigned refer to things that Stephen will probably change, such as HaloFinders -> halo_finders. I will change things like this according to this convention. Maybe we should reply to this with a list of files we changed, just to make sure we get all the imports right.
I'm fine with you changing things in stuff I've written to correspond to changes you've just made. Is that what you did, anyway (I hope!)?
_______________________________________________________ sskory@physics.ucsd.edu o__ Stephen Skory http://physics.ucsd.edu/~sskory/ _.>/ _Graduate Student ________________________________(_)_\(_)_______________ _______________________________________________ Yt-dev mailing list Yt-dev@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
_______________________________________________ Yt-dev mailing list Yt-dev@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
Ok, I just did:
LightCone.py -> light_cone.py
HaloProfiler.py -> halo_profiler.py
Clump.py -> clump.py
Britton
On Mon, Jun 7, 2010 at 8:37 PM, Matthew Turk
I agree, yes -- when you rename a module, it's fine to fix all the other imports that reference that module.
-Matt
Matt has pointed out to me that the HaloFinding that I referenced did not actually count, since that itself wasn't the Class. I am actually changing my mind on this point anyway. We should probably just be in charge of changing all import statements in all files when we do the file name changing. That way we run a smaller risk of having broken imports for a period of time.
Britton
On Mon, Jun 7, 2010 at 8:26 PM, Stephen Skory
wrote: Britton,
Some of the files I've been assigned refer to things that Stephen will probably change, such as HaloFinders -> halo_finders. I will change
like this according to this convention. Maybe we should reply to
On Mon, Jun 7, 2010 at 2:36 PM, Britton Smith
wrote: things this with a list of files we changed, just to make sure we get all the imports right.
I'm fine with you changing things in stuff I've written to correspond to changes you've just made. Is that what you did, anyway (I hope!)?
_______________________________________________________ sskory@physics.ucsd.edu o__ Stephen Skory http://physics.ucsd.edu/~sskory/ http://physics.ucsd.edu/%7Esskory/_.>/ _Graduate Student ________________________________(_)_\(_)_______________ _______________________________________________ Yt-dev mailing list Yt-dev@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
_______________________________________________ Yt-dev mailing list Yt-dev@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
_______________________________________________ Yt-dev mailing list Yt-dev@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
In svn (1744), and in yt-doc (9854b43eedcc) I renamed and changed all mentions of MergerTree.py -> merger_tree.py HaloMassFcn.py -> halo_mass_function.py _______________________________________________________ sskory@physics.ucsd.edu o__ Stephen Skory http://physics.ucsd.edu/~sskory/ _.>/ _Graduate Student ________________________________(_)_\(_)_______________
participants (3)
-
Britton Smith
-
Matthew Turk
-
Stephen Skory