epam / epam/Indigo

Macro: System should allow '*' symbol at the beginning of peptide sequence

Open
#3,811 3 comments 0 reactions 0 assignees View on GitHub
FASTA Priority: Low
Dominant language
C++
Stars
406
Forks
134
Avg merge
2d 11h
Merged PRs (30d)
24

Description

**Steps to Reproduce**
1. Select Macromolecules mode:
Image
2. Copy the following structure in FASTA format:

```
>That should be allowed
*AAAA
```
3. Click the folder icon "Open..." in the top left corner of the top panel
Image

4. In Open Structure pop-up expand the format dropdown by clicking on preselected "Ket" value and select FASTA format:

![Image](https://github.com/user-attachments/assets/cc82f97a-3da3-489f-aaa5-b5e0042d2d9f)

5. Paste the previously copied structure using Ctrl+V
6. Click the "Open as New" button:

Image

**Actual behavior**
System throws an error: Convert error! Given string could not be loaded as (query or plain) molecule or reaction, see the error messages
![image](https://github.com/epam/Indigo/assets/26869421/cd91110e-dfaa-4813-a38d-0f64615c40b3)

**Expected behavior**
System loads peptide without errors
![image](https://github.com/epam/Indigo/assets/26869421/846b5a54-325e-4867-a279-55c693f66186)

As per requirement description (https://github.com/epam/Indigo/issues/1755#issuecomment-1972978475):
>`"*"` means the end of the peptide sequence
>If `" * "` occurred between two letters then it should be recognized as the break in peptide chain (no bond should be created between monomers separated with the `"*"`).
Confirmed by @olganaz

**Environment details:**
Ketcher Version 2.20.0-rc.2 Build at 2024-03-27; 08:30:51
Indigo Toolkit Version 1.19.0-rc.2.0-g6c0e3fecf-x86_64-linux-gnu-11.2.1
Win10
Chrome Version 122.0.6261.129 (Official Build) (64-bit)

**Related issues:**
- https://github.com/epam/Indigo/issues/1755
- https://github.com/epam/ketcher/issues/4280

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing the FASTA import through the Open Structure dialog with the `*AAAA` sequence, then trace the FASTA loading and conversion path involved. Review the linked requirement in issue 1755; done means a peptide beginning with `*` loads without a conversion error and preserves the expected sequence behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.