diff --git a/modules/conop/doc/compoundlib.rst b/modules/conop/doc/compoundlib.rst index 018946c42bfce9857da96204b2505bb789768ed8..d211f631e4fa3f980a71381bc5adc15c8355979d 100644 --- a/modules/conop/doc/compoundlib.rst +++ b/modules/conop/doc/compoundlib.rst @@ -156,14 +156,14 @@ build the compound library manually. .. attribute:: inchi - The InChI code of this compound, without the 'InChI=' part, e.g - '1S/H2O/h1H2' for water. Read-only. + The InChI code of this compound, e.g '1S/H2O/h1H2' for water. + Read-only. :type: :class:`str` .. attribute:: inchi_key - The InChIKey of this compound without the 'InChIKey=' part, e.g. + The InChIKey of this compound, e.g. 'XLYOFNOQVPJJNP-UHFFFAOYSA-N' for water. Read-only. :type: :class:`str` diff --git a/modules/io/src/mol/chemdict_parser.cc b/modules/io/src/mol/chemdict_parser.cc index 5e138f03dbd500f88a207321c6fc0ddcac462191..5bdd156edd5044f3122f15446b1e1459a7386a6d 100644 --- a/modules/io/src/mol/chemdict_parser.cc +++ b/modules/io/src/mol/chemdict_parser.cc @@ -85,7 +85,7 @@ void ChemdictParser::OnDataRow(const StarLoopDesc& header, "'InChI=' prefix." << std::endl; return; } - compound_->SetInchi(columns[indices_[DESC]].substr(6).str()); + compound_->SetInchi(columns[indices_[DESC]].str()); } else if (columns[indices_[DESC_TYPE]] == StringRef("InChIKey", 8)) { compound_->SetInchiKey(columns[indices_[DESC]].str()); } else if (columns[indices_[DESC_TYPE]] == StringRef("SMILES_CANONICAL", 16) &&