S-group component with Arrow Open Angle is incorrectly converted into SMARTS (Arrow is moved outside the s-group component)
- Dominant language
- C++
- Stars
- 406
- Forks
- 134
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 24
Description
**Steps to Reproduce**
Create S-group component with Arrow Open Angle inside and try to convert that into SMARTS (save as SMARTS file).
**Expected behavior**
**Actual behavior**
At SMARTS Arrow is moved outside the s-group component e.g.:
```
([#1].[#8])>>
```
**Attachments**

**Technical details**
Method:
v2/indigo/convert
Payload options:
```
{
"smart-layout": true,
"ignore-stereochemistry-errors": true,
"mass-skip-error-on-pseudoatoms": false,
"gross-formula-add-rsites": true,
"aromatize-skip-superatoms": true,
"dearomatize-on-load": false,
"ignore-no-chiral-flag": false,
"gross-formula-add-isotopes": true
}
```
Payload structure:
```
{
"root": {
"nodes": [
{
"$ref": "mol0"
},
{
"type": "arrow",
"data": {
"mode": "open-angle",
"pos": [
{
"x": 10.575000000000001,
"y": -7.125,
"z": 0
},
{
"x": 13.425,
"y": -7.125,
"z": 0
}
]
}
}
]
},
"mol0": {
"type": "molecule",
"atoms": [
{
"label": "H",
"location": [
9.65,
-7.1000000000000005,
0
]
},
{
"label": "O",
"location": [
14.9,
-7.300000000000001,
0
]
}
],
"sgroups": [
{
"type": "queryComponent",
"atoms": [
0,
1
]
}
]
}
}
```
**Indigo/Bingo version**
Version 1.17.0-rc.2.0-g7501bfd6c-x86_64-linux-gnu-11.2.1
**Additional context**
When trying to open saved SMARTS file then error is shown: "Convert error! IndigoException: array: stack underflow"
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the v2/indigo/convert method and reproduce the conversion using the supplied payload, including the open-angle arrow and queryComponent s-group. Inspect how the saved SMARTS represents the arrow and verify that reopening it no longer raises the reported array stack underflow and keeps the arrow within the s-group component.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100