mailInsanely massive clean up of all of the Bieri GUI code base. (Re: r10295 - in /branches/bieri_gui/gui_bieri: ./ analyses/ execution/)


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by Edward d'Auvergne on January 24, 2010 - 14:44:
Hi Michael,

Please take note of this important commit!  Any future patches must be
up to date with this revision (r10295).  The code changes are so huge
that no patch will be usable from earlier revisions.  This has done
nothing to the functionality of the code.  The 2 most important changes
are the fixing of all whitespace issues, and the alphabetical ordering
of user functions.  Two other things which I accidentally left out of
the commit message are the clean up of imports and the conversion of
some of your function/method/class comments into docstrings where they
belong.

One thing which is more clear now with the alphabetical ordering is the
huge code duplication.  Many methods are not necessary.  For example in
gui_bieri.relax_gui, there are 4 exec_rx_*() methods which are
essentially identical.  This should only be one method, where the
relevant data is passed into the function (never accessed as a global
variable).  Also, where you use comments such as:

#####################################################################################################################

to break up the code, this is an indication that the code should be
broken up either into functions or into different modules (files).
These breaks should be in the code, not the comments.  For example, it
would be good to shift all the model-free GUI code into its own module
in gui_bieri.analyses.  I have many other points for improving the code
and bringing up to a higher, but I'll save these for later.

Regards,

Edward


P. S.  Note that if any future code (patches or commits when you are
given access) violates the coding standards, these will either not be
applied or automatically reversed and will need to be resubmitted in the
correct form.  If the editor you are currently using does not support
automatically setting the tab key to 4 spaces, please consider switching
to gvim, emacs, or some other more advanced editor.



On Sun, 2010-01-24 at 13:24 +0000, edward@xxxxxxxxxxxxx wrote:
Author: bugman
Date: Sun Jan 24 14:24:32 2010
New Revision: 10295

URL: http://svn.gna.org/viewcvs/relax?rev=10295&view=rev
Log:
Insanely massive clean up of all of the Bieri GUI code base.

Not much code has been unaffected by this change.  The changes include:

- Important fixes for the whitespace rule violations.  There were 
identified by the
'scripts/code_validator' script.  The number of spaces used for indentation 
was almost random and
hence impossible to work with.  Spacing between functions was not following 
the 2 empty line rule.
Non-arg assignments with '=' sometimes had no space or 2 spaces.  Comma 
separated elements (lists,
tuples, function args, etc.) often didn't have a space after the comma.  A 
few tab characters were
being used whereas '\t' should have been used.  There was trailing 
whitespace everywhere.

- All functions have been shifted to be before classes.

- All functions/methods have been alphabetically ordered.  This is 
important to follow the code.

- Classes were not always capitalised.

- Removed the executable properties from 
gui_bieri/analyses/select_model_calc.py.


Modified:
    branches/bieri_gui/gui_bieri/__init__.py
    branches/bieri_gui/gui_bieri/about.py
    branches/bieri_gui/gui_bieri/analyses/project.py
    branches/bieri_gui/gui_bieri/analyses/relax_control.py
    branches/bieri_gui/gui_bieri/analyses/results_analysis.py
    branches/bieri_gui/gui_bieri/analyses/select_model_calc.py   (contents, 
props changed)
    branches/bieri_gui/gui_bieri/execution/calc_modelfree.py
    branches/bieri_gui/gui_bieri/execution/calc_noe.py
    branches/bieri_gui/gui_bieri/execution/calc_rx.py
    branches/bieri_gui/gui_bieri/filedialog.py
    branches/bieri_gui/gui_bieri/message.py
    branches/bieri_gui/gui_bieri/relax_gui.py
    branches/bieri_gui/gui_bieri/settings.py

[This mail would be too long, it was shortened to contain the URLs only.]

Modified: branches/bieri_gui/gui_bieri/__init__.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/__init__.py?rev=10295&r1=10294&r2=10295&view=diff

Modified: branches/bieri_gui/gui_bieri/about.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/about.py?rev=10295&r1=10294&r2=10295&view=diff

Modified: branches/bieri_gui/gui_bieri/analyses/project.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/analyses/project.py?rev=10295&r1=10294&r2=10295&view=diff

Modified: branches/bieri_gui/gui_bieri/analyses/relax_control.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/analyses/relax_control.py?rev=10295&r1=10294&r2=10295&view=diff

Modified: branches/bieri_gui/gui_bieri/analyses/results_analysis.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/analyses/results_analysis.py?rev=10295&r1=10294&r2=10295&view=diff

Modified: branches/bieri_gui/gui_bieri/analyses/select_model_calc.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/analyses/select_model_calc.py?rev=10295&r1=10294&r2=10295&view=diff

Modified: branches/bieri_gui/gui_bieri/execution/calc_modelfree.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/execution/calc_modelfree.py?rev=10295&r1=10294&r2=10295&view=diff

Modified: branches/bieri_gui/gui_bieri/execution/calc_noe.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/execution/calc_noe.py?rev=10295&r1=10294&r2=10295&view=diff

Modified: branches/bieri_gui/gui_bieri/execution/calc_rx.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/execution/calc_rx.py?rev=10295&r1=10294&r2=10295&view=diff

Modified: branches/bieri_gui/gui_bieri/filedialog.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/filedialog.py?rev=10295&r1=10294&r2=10295&view=diff

Modified: branches/bieri_gui/gui_bieri/message.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/message.py?rev=10295&r1=10294&r2=10295&view=diff

Modified: branches/bieri_gui/gui_bieri/relax_gui.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/relax_gui.py?rev=10295&r1=10294&r2=10295&view=diff

Modified: branches/bieri_gui/gui_bieri/settings.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/settings.py?rev=10295&r1=10294&r2=10295&view=diff


_______________________________________________
relax (http://nmr-relax.com)

This is the relax-commits mailing list
relax-commits@xxxxxxx

To unsubscribe from this list, get a password
reminder, or change your subscription options,
visit the list information page at
https://mail.gna.org/listinfo/relax-commits





Related Messages


Powered by MHonArc, Updated Mon Jan 25 00:00:12 2010