Impossible to calculate properties of the selected without R-Group label (or SRU polymer) part of the molecule
- Dominant language
- C++
- Stars
- 406
- Forks
- 134
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 24
Description
Affected versions: Standalone
_Scenario 1._
Steps to reproduce:
1. Launch Ketcher.
2. Draw a structure, e.g. chain.
3. Add R-Group Label (e.g. R1) to one of the atoms with 'R-Group label tool'.
4. Select with 'Lasso selection' tool a part of the structure without the R-Group label.
5. Click on the 'Calculated values' button.
Expected result: The 'Calculated values' window is opened. All the fields are filled with the correct data.
Actual result: The 'Calculated values' window is opened with the following data: 'Chemical Formula' field is filled with the correct formula, 'Molecular Weight'/'Exact Mass'/'Elemental Analysis' fields are filled with 'mass: Cannot calculate mass for structure with pseudoatoms, template atoms or RSites' warning.

_Scenario 2._
Steps to reproduce:
1. Draw a structure, e.g. chain.
2. Define a part of the created structure as SRU polymer with S-Group tool.
3. Select with 'Lasso selection' tool a part of the structure outside the brackets of the SRU polymer.
4. Click on the 'Calculated values' button.
Expected result: 'Chemical Formula', 'Molecular Weight', 'Exact Mass', 'Elemental Analysis' fields in the 'Calculated values' window are filled with the correct data.
Actual result: The 'Calculated values' window is opened with the following data: 'Chemical Formula' field is filled with incorrect data (C6H13()n), 'Molecular Weight'/'Exact Mass'/'Elemental Analysis' fields are filled with 'mass: Cannot calculate mass for structure with repeating units' warning.

_Scenario 3._
Steps to reproduce:
1. Open [Attachment_points.zip](https://github.com/epam/ketcher/files/6829450/Attachment_points.zip)
2. Select with 'Lasso selection' tool a part of the structure without attachment
3. Click on the 'Calculated values' button.
Expected result: 'Chemical Formula', 'Molecular Weight', 'Exact Mass', 'Elemental Analysis' fields in the 'Calculated values' window are filled with the correct data in both standalone and remote mode.
Actual result:
In standalone mode there is alert window:

_Scenario 4._
Steps to reproduce:
1. Launch Ketcher
2. Open [SRU-polymer.zip](https://github.com/epam/ketcher/files/6829579/SRU-polymer.zip)
3. Select with 'Lasso selection' tool a part of the structure without S-group (SRU) or Select the part of structure in such a way that the part of S-group is selected (one bracket is present in the selected part).
4. Click the 'Calculated Values' button.
Expected result:
'Chemical Formula', 'Molecular Weight', 'Exact Mass', 'Elemental Analysis' fields in the 'Calculated values' window are filled with the correct data in both standalone and remote mode.
Actual result:
The 'Calculated values' window is opened with the following data: 'Chemical Formula' field is filled with correct data (C9H20(C6H12)n), 'Molecular Weight'/'Exact Mass'/'Elemental Analysis' fields are filled with 'mass: Cannot calculate mass for structure with repeating units' warning.

Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.