epam / epam/Indigo

The ordering of several separate reactions is changed after layout and save/load to/from RDF actions

Open
#2,584 0 comments 0 reactions 1 assignee Claimed by @even1024 View on GitHub
Cascade reactions MMPK Priority: High
Dominant language
C++
Stars
406
Forks
134
Avg merge
2d 11h
Merged PRs (30d)
24

Description

**Steps to Reproduce**
1. Add the reactions with single and multi-tailed arrow to canvas or load from file:
[ketcher-2452.zip](https://github.com/user-attachments/files/17522486/ketcher-2452.zip)
![image](https://github.com/user-attachments/assets/8d8e0945-b0ba-4eca-ba0e-c7438a7a35af)
2. Make save/load to RDF or layout actions

**Actual behavior**
- Reactions are aligned, but the ordering is changed:
![image](https://github.com/user-attachments/assets/f591066e-ae9b-45f1-b681-ac5e3ab24b22)
- There is a separate issue that the reaction with a single arrow is changed to a reaction with Multi-Tailed Arrow after layout - https://github.com/epam/Indigo/issues/2451

**Expected behavior**
- Reactions are aligned, the ordering is the same as in step 1

**Environment details:**
Reproduced on RC SA env:
- Ketcher [Version 2.26.0-rc.6] Build at 2024-10-25; 09:57:12;
- Indigo Version 1.25.0-rc.4.0-g8862ccb7e-wasm32-wasm-clang-19.0.0
- Desktop, Windows 11 Enterprise
- Chrome, Version 130.0.6723.70 (Official Build) (64-bit)

**Additional context**
- The cases are added to xls and have to be automated for cases with several single reactions and several cascade reactions
- Also there is an issue for loading from RDF. There are 6 different combinations of 3 reactions with the same product and matching by reactant/product:
[6-cases.zip](https://github.com/user-attachments/files/17572931/6-cases.zip)
On the left side there are information about sequence of reactions in RDF file and on the right side how it looks on Canvas after loading, as you can see in cases #4 and #6 sequence isn't correct, cascade reaction should be the first:
![image](https://github.com/user-attachments/assets/eeb8d185-59de-48e1-9f8f-11e9e3b4fe02)
- **Also it can be reproduced for several cascade reactions**:
[ket-ordering-issue.zip](https://github.com/user-attachments/files/17540252/ket-ordering-issue.zip)
- After loading from KET:
![image](https://github.com/user-attachments/assets/00c876ce-ba62-4862-aee8-14f6d51a7620)
- After save/load to/from RDF or layout:
![image](https://github.com/user-attachments/assets/e30ddb91-46ae-4d48-9927-29559f737db0)
- The defect is detected during retesting of fix for https://github.com/epam/Indigo/issues/2452, but initially, it's related to https://github.com/epam/Indigo/issues/2422

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.