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

Temporarily remove GAFF because of parmchk2 issues #329

Merged
merged 13 commits into from
May 3, 2024

Conversation

mattwthompson
Copy link
Collaborator

@mattwthompson mattwthompson commented May 2, 2024

No description provided.

Comment on lines -46 to -53
- name: License OpenEye
shell: bash -l {0}
run: |
echo "${SECRET_OE_LICENSE}" > ${OE_LICENSE}
python -c "from openeye import oechem; assert oechem.OEChemIsLicensed()"
env:
SECRET_OE_LICENSE: ${{ secrets.OE_LICENSE }}

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was not needed for direct API access or exclusive functionality, it was just to get charge assignment running faster. This can be re-added at any time provided the org's license is managed, or NAGL could be used as a replacement for quicker charge assignment in tests

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will update the license, but I am thinking that I will (after this PR) add this section in but add some logic to only install openeye/check license if it is not a fork so CI can still be fast sometimes but a PR from an outside contributor doesn't just fail.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IIUC, that's not necessary if the license is set up as an org secret. OpenFF's setup has worked great for a while; it pulls down the secret in a way that can't be cat'd out from a fork since it's not accessible at all. The slightly annoying thing is CI always fails from a fork, which I think is an okay price to pay for this level of security

https://github.com/openforcefield/openff-toolkit/blob/62b615cb6e3ea2561b869bbd70adaeea90fc04ea/.github/workflows/CI.yml#L87-L92

openforcefield/openff-interchange#962

def __init__(self, forcefields=None, small_molecule_forcefield='openff-1.0.0', forcefield_kwargs=None, nonperiodic_forcefield_kwargs=None, periodic_forcefield_kwargs=None, template_generator_kwargs=None, barostat=None, molecules=None, cache=None, postprocess_system=None):
def __init__(self, forcefields=None, small_molecule_forcefield='openff-2.2.0', forcefield_kwargs=None, nonperiodic_forcefield_kwargs=None, periodic_forcefield_kwargs=None, template_generator_kwargs=None, barostat=None, molecules=None, cache=None, postprocess_system=None):
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not the update from (the first) Parsley to (the newest) Sage

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea! We will want to make sure we mention that in the changelog/release notes

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea - I'm adding a couple of notes to the changelog section of the README

except ValueError as e:
except (ValueError, NotImplementedError) as e:
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is to catch the way I nuked GAFFTemplateGenerator, probably something that should be reverted alongside adding it back

class TestGAFFTemplateGenerator(unittest.TestCase):
TEMPLATE_GENERATOR = GAFFTemplateGenerator

amber_forcefields = ['amber/protein.ff14SB.xml', 'amber/tip3p_standard.xml', 'amber/tip3p_HFE_multivalent.xml']
class TemplateGeneratorBaseCase(unittest.TestCase):
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The diff here is large, but the basic change is refactoring out the non-GAFF stuff from TestGAFFTemplateGenerator into a new TemplateGeneratorBaseCase; previously both SMIRNOFF and Espaloma tests subclassed from it, which make it impossible to run while skipping GAFF tests

@mattwthompson mattwthompson marked this pull request as ready for review May 3, 2024 13:22
@@ -107,4 +100,4 @@ jobs:
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml
fail_ci_if_error: true
fail_ci_if_error: false # I don't want this to cause CI failures when a developer pushes to a fork
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

      if: ${{ github.repository == 'openmm/openmmforcefields'
              && github.event != 'schedule' }}

I thought this logic would prevent that, but if it wasn't working then this change is great for the same reasons we got rid of the openeye license

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also expect this to skip it from being run from a fork 🤷‍♂️

"thereby the GAFFTemplateGenerator class. Support will be re-introduced in "
"future releases (0.14.x). To use this class, install version 0.12.0 or older."
)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am happy with this error message

@mikemhenry
Copy link
Collaborator

🤌 those release notes 🔥

@mattwthompson
Copy link
Collaborator Author

I like to keep release notes brief (the changes of me introducing a typo scale linearly with number of words)

@mikemhenry mikemhenry merged commit b685637 into openmm:main May 3, 2024
6 checks passed
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.

None yet

2 participants