You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, the behaviour of DownloadChemCompProvider is to return null when an IOExcption occurred in obtaining the chemical component information of a Group. This null causes the Group to be ignored and it is not included in the loaded Structure.
A fail-back behaviour could be implemented so that if an IOException occurred, the ReducedChemCompProvider is used. Instead of ignoring the Group, now it will be included with the ChemComp information included in BioJava or with an empty ChemComp.
This will allow the loading of structures with the DownloadChemCompProvider even if there is not internet connection, in which case the ReducedChemCompProvider will be used. In the case of having internet connection the loaded structure will have more information, but the internet resources are not a necessary requisite for loading structures.
This relates to discussion in #314, because, with this fail-back behaviour, the DownloadChemCompProvider could be used as the default provider and no extra resources would be needed outside the biojava ones. If they are available, they will be used, unless the user explicitly sets the provider to the ReducedChemCompProvider.
I like the idea of the fail-back behaviour. It still allows for forcing to use ReducedChemCompProvider if the user needs specially fast structure loading.
We have also seen that the backbone information of the structure can be obtained from the mmCIF file, because there is some part of the Chemical Component information ("L-peptide-linking tag for aminoacids in the backbone). This would not be valid for non-deposited structure files, but at least will solve the issues with the structures downloaded from the PDB, without downloading the Chemical Component (ReducedChemCompProvider). If other information from the Chemical Component file is needed it would not be available, for example the parent residue.
The logger messages in DownloadChemCompProvider were kept in ERROR level after the fail-back behavior was implemented. They should be changed to WARN or INFO, because the chemical component information is returned if the ReducedChemComp succeeds.
ERROR messages should only be printed if the ChemComp information cannot be attached to the final Structure object. Otherwise misleading ERROR messages are printed, like when running algorithms offline (see rcsb/symmetry#76).
@lafita is this still relevant? are those logging messages still coming up? If so, could you post an example? If not relevant anymore then let's close.
Activity
josemduarte commentedon Aug 5, 2015
+1
I like the idea of the fail-back behaviour. It still allows for forcing to use
ReducedChemCompProviderif the user needs specially fast structure loading.lafita commentedon Aug 11, 2015
We have also seen that the backbone information of the structure can be obtained from the mmCIF file, because there is some part of the Chemical Component information ("L-peptide-linking tag for aminoacids in the backbone). This would not be valid for non-deposited structure files, but at least will solve the issues with the structures downloaded from the PDB, without downloading the Chemical Component (ReducedChemCompProvider). If other information from the Chemical Component file is needed it would not be available, for example the parent residue.
#315 instead of returning null, now try to look up ChemComps in a Red…
andreasprlic commentedon Jan 31, 2016
Added ReducedChemCompProvider as the fallback.
lafita commentedon May 17, 2016
The
loggermessages inDownloadChemCompProviderwere kept in ERROR level after the fail-back behavior was implemented. They should be changed to WARN or INFO, because the chemical component information is returned if theReducedChemCompsucceeds.ERROR messages should only be printed if the ChemComp information cannot be attached to the final
Structureobject. Otherwise misleading ERROR messages are printed, like when running algorithms offline (see rcsb/symmetry#76).josemduarte commentedon Aug 29, 2018
@lafita is this still relevant? are those logging messages still coming up? If so, could you post an example? If not relevant anymore then let's close.
Merge pull request #803 from lafita/master