Author: bugman Date: Fri Feb 27 17:28:52 2009 New Revision: 8890 URL: http://svn.gna.org/viewcvs/relax?rev=8890&view=rev Log: Switched from a RelaxError to 'non-polymer' for anything that isn't a polymer. A RelaxWarning is thrown so the user can check for FUBAR entries. Modified: branches/bmrb/generic_fns/mol_res_spin.py Modified: branches/bmrb/generic_fns/mol_res_spin.py URL: http://svn.gna.org/viewcvs/relax/branches/bmrb/generic_fns/mol_res_spin.py?rev=8890&r1=8889&r2=8890&view=diff ============================================================================== --- branches/bmrb/generic_fns/mol_res_spin.py (original) +++ branches/bmrb/generic_fns/mol_res_spin.py Fri Feb 27 17:28:52 2009 @@ -514,9 +514,10 @@ res_names = get_residue_names("#" + mol_names[i]) res_nums = get_residue_nums("#" + mol_names[i]) - # Test for a polymer. - if not len(res_nums): - raise RelaxError, "Non-polymer molecules are not yet supported." + # Find the molecule type. + if len(res_nums) < 4: + mol_type = 'non-polymer' + warn(RelaxWarning("The molecule '%s' is assumed to be a non-polymer, i.e. an organic molecule, ligand, metal ion, etc. It should not be a solvent molecule!")) else: mol_type = 'polymer'