Skip to content

Utility functions for determining the smallest ring size of an atom/b… - #820

Merged
egonw merged 1 commit into
masterfrom
patch/small-ring-size
Feb 7, 2022
Merged

Utility functions for determining the smallest ring size of an atom/b…#820
egonw merged 1 commit into
masterfrom
patch/small-ring-size

Conversation

@johnmay

@johnmay johnmay commented Feb 6, 2022

Copy link
Copy Markdown
Member

…ond.

Addresses #562.

There are some places where this simplifies existing logic (Expr/StereoElementFactory) but we need to wait till AtomContainer -> AtomContainer2 happens (of which I now think we have reached that point).

@sonarqubecloud

sonarqubecloud Bot commented Feb 6, 2022

Copy link
Copy Markdown

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 2 Code Smells

0.0% 0.0% Coverage
0.0% 0.0% Duplication

@egonw
egonw merged commit 44ef05b into master Feb 7, 2022
@egonw

egonw commented Feb 7, 2022

Copy link
Copy Markdown
Member

Looks good to me. We used to have independent classes for this, reflecting multiple algorithms.

@johnmay

johnmay commented Feb 7, 2022

Copy link
Copy Markdown
Member Author

Yeah I was tempted, like the vertex/edge short I have. This was more for utility and efficient on lazy single atom/bond checks. This is useful in at least two places SMARTS (we don't need all ring sizes only when the expr is checked) and Stereo perception of double bonds (i.e. don't set cis/trans in benzene).

Unfortunately I can't replace these usages yet until AtomContainer2 is the main implementation - i.e. there are tests calling new AtomContainer() rather than use the builder.

@johnmay
johnmay deleted the patch/small-ring-size branch February 9, 2022 15:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants