Author: bugman Date: Sun Nov 4 13:39:20 2007 New Revision: 3399 URL: http://svn.gna.org/viewcvs/relax?rev=3399&view=rev Log: Renamed all instances of RelaxRunError with RelaxPipeError, and modified the error message. Modified: 1.3/data/__init__.py 1.3/generic_fns/pipes.py 1.3/relax_errors.py 1.3/specific_fns/hybrid.py 1.3/test_suite/unit_tests/generic_fns/test_pipes.py 1.3/test_suite/unit_tests/generic_fns/test_residue.py Modified: 1.3/data/__init__.py URL: http://svn.gna.org/viewcvs/relax/1.3/data/__init__.py?rev=3399&r1=3398&r2=3399&view=diff ============================================================================== --- 1.3/data/__init__.py (original) +++ 1.3/data/__init__.py Sun Nov 4 13:39:20 2007 @@ -25,7 +25,7 @@ # relax module imports. from pipe_container import PipeContainer -from relax_errors import RelaxRunError +from relax_errors import RelaxPipeError __all__ = [ 'data_classes', @@ -114,7 +114,7 @@ # Test if the pipe already exists. if pipe_name in self.keys(): - raise RelaxRunError, pipe_name + raise RelaxPipeError, pipe_name # Create a new container. self[pipe_name] = PipeContainer() Modified: 1.3/generic_fns/pipes.py URL: http://svn.gna.org/viewcvs/relax/1.3/generic_fns/pipes.py?rev=3399&r1=3398&r2=3399&view=diff ============================================================================== --- 1.3/generic_fns/pipes.py (original) +++ 1.3/generic_fns/pipes.py Sun Nov 4 13:39:20 2007 @@ -22,7 +22,7 @@ # relax module imports. from data import Data as relax_data_store -from relax_errors import RelaxError, RelaxNoPipeError, RelaxRunError +from relax_errors import RelaxError, RelaxNoPipeError, RelaxPipeError from specific_fns.relax_fit import C_module_exp_fn @@ -46,7 +46,7 @@ # Test if the pipe already exists. if pipe_to in relax_data_store.keys(): - raise RelaxRunError, pipe_to + raise RelaxPipeError, pipe_to # The current data pipe. if pipe_from == None: Modified: 1.3/relax_errors.py URL: http://svn.gna.org/viewcvs/relax/1.3/relax_errors.py?rev=3399&r1=3398&r2=3399&view=diff ============================================================================== --- 1.3/relax_errors.py (original) +++ 1.3/relax_errors.py Sun Nov 4 13:39:20 2007 @@ -511,13 +511,13 @@ self.save_state() -# Run errors. -############# - -# Run already exists. -class RelaxRunError(BaseError): - def __init__(self, run): - self.text = "The run " + `run` + " already exists." +# Data pipe errors. +################### + +# The data pipe already exists. +class RelaxPipeError(BaseError): + def __init__(self, pipe): + self.text = "The data pipe " + `pipe` + " already exists." if Debug: self.save_state() Modified: 1.3/specific_fns/hybrid.py URL: http://svn.gna.org/viewcvs/relax/1.3/specific_fns/hybrid.py?rev=3399&r1=3398&r2=3399&view=diff ============================================================================== --- 1.3/specific_fns/hybrid.py (original) +++ 1.3/specific_fns/hybrid.py Sun Nov 4 13:39:20 2007 @@ -22,7 +22,7 @@ # relax module imports. from data import Data as relax_data_store -from relax_errors import RelaxError, RelaxNoPipeError, RelaxNoSequenceError, RelaxRunError, RelaxSequenceError +from relax_errors import RelaxError, RelaxNoPipeError, RelaxNoSequenceError, RelaxPipeError, RelaxSequenceError # The relax data storage object. @@ -62,7 +62,7 @@ # Test if the hybrid run already exists. if hybrid in relax_data_store.run_names: - raise RelaxRunError, hybrid + raise RelaxPipeError, hybrid # Loop over the runs to be hybridised. for run in runs: Modified: 1.3/test_suite/unit_tests/generic_fns/test_pipes.py URL: http://svn.gna.org/viewcvs/relax/1.3/test_suite/unit_tests/generic_fns/test_pipes.py?rev=3399&r1=3398&r2=3399&view=diff ============================================================================== --- 1.3/test_suite/unit_tests/generic_fns/test_pipes.py (original) +++ 1.3/test_suite/unit_tests/generic_fns/test_pipes.py Sun Nov 4 13:39:20 2007 @@ -27,7 +27,7 @@ from data import Data as relax_data_store from data.pipe_container import PipeContainer from generic_fns import pipes -from relax_errors import RelaxError, RelaxNoPipeError, RelaxRunError +from relax_errors import RelaxError, RelaxNoPipeError, RelaxPipeError class Test_pipes(TestCase): @@ -129,8 +129,8 @@ The function tested is generic_fns.pipes.copy() """ - # Assert that a RelaxRunError occurs when the data pipe to copy data to already exists. - self.assertRaises(RelaxRunError, pipes.copy, 'orig', 'empty') + # Assert that a RelaxPipeError occurs when the data pipe to copy data to already exists. + self.assertRaises(RelaxPipeError, pipes.copy, 'orig', 'empty') def test_creation(self): Modified: 1.3/test_suite/unit_tests/generic_fns/test_residue.py URL: http://svn.gna.org/viewcvs/relax/1.3/test_suite/unit_tests/generic_fns/test_residue.py?rev=3399&r1=3398&r2=3399&view=diff ============================================================================== --- 1.3/test_suite/unit_tests/generic_fns/test_residue.py (original) +++ 1.3/test_suite/unit_tests/generic_fns/test_residue.py Sun Nov 4 13:39:20 2007 @@ -27,7 +27,7 @@ from data import Data as relax_data_store from data.pipe_container import PipeContainer from generic_fns import residue -from relax_errors import RelaxError, RelaxNoPipeError, RelaxRunError, RelaxSpinSelectDisallowError +from relax_errors import RelaxError, RelaxNoPipeError, RelaxSpinSelectDisallowError class Test_residue(TestCase):