Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add simple atom query primitives to the query specific properties #3298

Closed
AlexanderSavelyev opened this issue Sep 12, 2023 · 4 comments · Fixed by #3322
Closed

Add simple atom query primitives to the query specific properties #3298

AlexanderSavelyev opened this issue Sep 12, 2023 · 4 comments · Fixed by #3322

Comments

@AlexanderSavelyev
Copy link
Contributor

AlexanderSavelyev commented Sep 12, 2023

Background
Current set of atom query features lacks certain attributes supported by SMARTS standard. Missing features should be supported in Ketcher per below specification

Solution

1. Add following properties into the "Atom Properties/Query Specific" list of atom attributes.

  • Aromaticity (drop-down)
    • empty (default)
    • aromatic
    • aliphatic
  • Degree (drop-down)
    • empty (default)
    • 0
    • 1
    • 2
    • 3
    • 4
    • 5
    • 6
  • Implicit H count (drop-down)
    • empty (default)
    • 0
    • 1
    • 2
    • 3
    • 4
  • Ring membership (drop-down)
    • empty (default)
    • 0
    • 1
    • 2
    • 3
    • 4
    • 5
  • Ring size (drop-down)
    • empty (default)
    • 0
    • 1
    • 2
    • 3
    • 4
    • 5
  • Connectivity (drop-down)
    • empty (default)
    • 0
    • 1
    • 2
    • 3
    • 4
    • 5
  • Ring connectivity (drop-down)
    • empty (default)
    • 0
    • 1
    • 2
    • 3
    • 4
    • 5
  • Chirality (drop-down)
    • empty (default)
    • anticlockwise
    • clockwise
  • Atomic mass (input field)
    • empty (default)
    • any number (> 0, < 1000)

2. Add following properties into the right click menu for the atoms/Query Properties (take values from the table above)

  • Aromaticity
  • Degree
  • Implicit H count
  • Ring membership
  • Ring size
  • Connectivity
  • Ring connectivity

3. Replace comma with semicolon between Atom properties:

image

Atom query properties should be stored in and loaded from KET format per specification provided in #3323

@MartaWilliams
Copy link
Collaborator

Test cases written

AKZhuk added a commit that referenced this issue Sep 18, 2023
…ties

- update e2e snapshots for save-file.spec.ts
AKZhuk added a commit that referenced this issue Sep 19, 2023
…ties

- hide implicitHCount if atom in aromatized ring
Nitvex pushed a commit that referenced this issue Sep 19, 2023
…ties (#3322)

* #3298 - Add simple atom query primitives to the query specific properties

* #3298 - Add simple atom query primitives to the query specific properties
- update e2e tests

* #3298 - Add simple atom query primitives to the query specific properties
- update e2e tests

* #3298 - Add simple atom query primitives to the query specific properties
- update e2e snapshots for save-file.spec.ts

* #3298 - Add simple atom query primitives to the query specific properties
- hide implicitHCount if atom in aromatized ring
@urszula-gawlowska urszula-gawlowska self-assigned this Oct 4, 2023
@ViktoriaTkacheva
Copy link
Collaborator

  1. When saving a structure with Atom Properties in .Ket format, in Preview the "hCount" indicator in different cases is constantly greater by 1 than it is displayed on the canvas
image
  1. If add Atom Properties to the structure (see the screenshot below) and click "Save as", an error is displayed, but this error can be closed, and save the file. The file opens correctly in .Ket format, but distorted in .mol format (not all Atom Properties are displayed)
image
  1. If add slightly different Atom Properties to the structure (see the screenshot below) and save it in .Ket format, then when opening this file, an error appears and the file does not open
image

@AKZhuk
Copy link
Collaborator

AKZhuk commented Oct 5, 2023

  1. When saving a structure with Atom Properties in .Ket format, in Preview the "hCount" indicator in different cases is constantly greater by 1 than it is displayed on the canvas
image 2. If add Atom Properties to the structure (see the screenshot below) and click "Save as", an error is displayed, but this error can be closed, and save the file. The file opens correctly in .Ket format, but distorted in .mol format (not all Atom Properties are displayed) image 3. If add slightly different Atom Properties to the structure (see the screenshot below) and save it in .Ket format, then when opening this file, an error appears and the file does not open image

1 - not a bug, the same behaviour in version 2.13.0
2,3 - - fixed in #3398

@ViktoriaTkacheva
Copy link
Collaborator

  1. The bug has been moved to a separate ticket An error appears when saving a structure with Atom Properties from the "Query specific" section Indigo#1311
  2. The bug is fixed

@AKZhuk AKZhuk removed this from the Ketcher 2.16.0-rc.1 milestone Oct 18, 2023
@AKZhuk AKZhuk added this to the SMART-Enhancement milestone Oct 18, 2023
@Nitvex Nitvex modified the milestones: SMART Enhancement, Ketcher 2.16.0-rc.1 Oct 23, 2023
@github-project-automation github-project-automation bot moved this to Done in Ketcher Aug 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

6 participants