Skip to content

Commit

Permalink
Merge pull request #280 from Becksteinlab/versioningit
Browse files Browse the repository at this point in the history
General clean up and modernization
- fix #278
- update to using pyproject.toml only #278
- replace setup.py with full pyproject.toml
- replace versioneer with versioningit
- clean up old code in tests (setup method replace with fixtures, removed old Python 2 cruft)

supported packages
- test GROMACS 2024 (also now on macOS)

CI
- fix RTD build
- fix macOS runners (2018.6 needed to be replaced by 2024.2)

release 0.9.0
- finalized CHANGES
  • Loading branch information
orbeckst authored Jun 15, 2024
2 parents ea118ed + 894cc22 commit 5619cca
Show file tree
Hide file tree
Showing 28 changed files with 206 additions and 3,239 deletions.
28 changes: 18 additions & 10 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
python-version: ["3.9", "3.10", "3.11", "3.12"]
gromacs-version: ["2023.1"]
# Test other GROMACS versions selectively on a recent Python.
# On macOS only test one GROMACS version and two Python versions
Expand All @@ -50,25 +50,33 @@ jobs:
- os: ubuntu-latest
python-version: "3.11"
gromacs-version: "2022.4"
# explicitly include a few macOS runners: MUST use 2018.6:
# (conda-forge GROMACS >= 2021 is compiled to use rdtscp CPU instruction but these
# are not available in the macOS GitHub runner so we need to use a different GROMACS
# version. 2018.5 from bioconda works. (2021.5 worked previously but not anymore.)
# Locally 2023.1 was successfully tested on Intel macOS 13.5.)
- os: ubuntu-latest
python-version: "3.11"
gromacs-version: "2023.4"
- os: ubuntu-latest
python-version: "3.11"
gromacs-version: "2024.2"
# explicitly include a few macOS runners; finding a version that works
# on the GH runners is tricky (eg some are compiled for rdtscp CPU instructions
# that are not available); 2018.6 (bioconda) worked for a while, but then stopped
# being resolved. 2024.2 (conda-forge) runs at the moment
- os: macOS-latest
python-version: "3.11"
gromacs-version: "2018.6"
gromacs-version: "2024.2"
- os: macOS-latest
python-version: "3.12"
gromacs-version: "2018.6"
gromacs-version: "2024.2"


env:
MPLBACKEND: agg


steps:
- uses: actions/checkout@v3
- name: git checkout
uses: actions/checkout@v4
with:
fetch-tags: true

- name: micromamba package and testing environment installation (Python ${{ matrix.python-version }}, GROMACS ${{ matrix.gromacs-version }})
uses: mamba-org/setup-micromamba@v1
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ dist
gromacs.log
doc/sphinx/*.log
*~

# aut-generated by versioningit
gromacs/_version.py
12 changes: 6 additions & 6 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@ sphinx:
# Optionally build your docs in additional formats such as PDF and ePub
formats: all

#### Ignored when using conda
# python:
# install:
# - method: pip
# path: .
# - requirements: ci/readthedocs/requirements.txt

# install package
python:
install:
- method: pip
path: .

conda:
environment: ci/readthedocs/environment.yml
13 changes: 11 additions & 2 deletions CHANGES
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,25 @@
CHANGELOG for GromacsWrapper
==============================

2023-xx-xx 0.9.0
2024-06-15 0.9.0
orbeckst, jandom, njzjz

* officially support Python 3.12 (PR #271, issue #263)
* removed support for legacy Python (<= 3.7) (#259)
* supports GROMACS 2024.2 (PR #280)
* removed support for legacy Python (<= 3.8) (#259)
* fixed GROMACS TOP reader not reading angle parameters from topology
file (#261)
* fixed Python 3.12: No module named ('pkg_resources' #263)
* fixed AttributeDict does not support hasattr (#214)
* fixed handle KeyboardInterrupts when using MDRunner.run() (#252)
* internally switched to pyproject.toml (#278)
* Pending Deprecation for the gw-*.py scripts:

The gw-*.py scripts are NOT anymore installed (it's technically
messy with the new system #278 and requires code refactoring). They
will likely be DEPRECATED. See issue #279 for more details and voice
your opinion if you really need these scripts.



2023-09-16 0.8.5
Expand Down
3 changes: 1 addition & 2 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
include setup.py COPYING README.rst CHANGES AUTHORS
include COPYING README.rst CHANGES AUTHORS
recursive-include scripts *.py
graft gromacs/templates/
include versioneer.py
include gromacs/_version.py
12 changes: 6 additions & 6 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@

A primitive Python wrapper around the Gromacs_ tools. The library is
tested with GROMACS 4.6.5, 2018.x, 2019.x, 2020.x, 2021.x, 2022.x,
2023.x (and 5.x and 2016.x should also work). It supports Python
3.8--3.12 on Linux and macOS.
2023.x, 2024.x (and 5.x and 2016.x should also work). It supports
Python 3.9--3.12 on Linux and macOS.

GromacsWrapper also provides a small library (cook book) of often-used
recipes and helper functions to set up MD simulations.
Expand All @@ -22,9 +22,9 @@ available at https://gromacswrapper.readthedocs.org for recent releases.

The source code is available in the `GromacsWrapper git repository`_.

Please be aware that this is **beta** software that most definitely
contains bugs. It is *your* responsibility to ensure that you are
running simulations with sensible parameters.
Please be aware that this software is only minimally maintained and it
most definitely contains bugs. It is *your* responsibility to ensure
that you are running simulations with sensible parameters.

.. _Gromacs: http://www.gromacs.org
.. _Documentation:
Expand Down Expand Up @@ -165,7 +165,7 @@ your own development::
Questions
=========

Please ask questions in the `Issue Tracker`_ (instead of private email).
Please ask questions in the `Discussion forum`_ (instead of private email).


Reporting Bugs and Contributing to GromacsWrapper
Expand Down
2 changes: 1 addition & 1 deletion doc/sphinx/source/index.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ errors are logged to a file so that there exists a complete history of
what has been done.

GROMACS_ versions 4.6.x, 2016.x, 2018.x, 2019.x, 2020.x, 2021.x,
2022.x, and 2023.x are all supported. GromacsWrapper detects your
2022.x, 2023.x, 2024.x are all supported. GromacsWrapper detects your
Gromacs tools and provides them as :func:`gromacs.grompp`,
:func:`gromacs.mdrun`, etc, regardless of your Gromacs version, which
allows one to write scripts that are broadly Gromacs-version
Expand Down
13 changes: 6 additions & 7 deletions doc/sphinx/source/installation.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ these instructions. Ask for help in the `discussions`_ forum.
.. _Issue Tracker: https://github.com/Becksteinlab/GromacsWrapper/issues
.. _discussions:
https://github.com/Becksteinlab/GromacsWrapper/discussions
.. _setuptools: https://pypi.org/project/setuptools/


``pip`` installation
Expand Down Expand Up @@ -70,12 +69,12 @@ If your prefer to download manually, get the latest stable release
from https://github.com/Becksteinlab/GromacsWrapper/releases and
either ::

pip install GromacsWrapper-0.8.5.tar.gz
pip install GromacsWrapper-0.9.0.tar.gz

or install from the unpacked source::

tar -zxvf GromacsWrapper-0.8.5.tar.gz
cd GromacsWrapper-0.8.5
tar -zxvf GromacsWrapper-0.9.0.tar.gz
cd GromacsWrapper-0.9.0
pip install .


Expand All @@ -102,16 +101,16 @@ formatting so please install black_ and run it on your code.
Requirements
============

Python_ >= 3.8 and GROMACS_ (4.6.x, 2016, 2018, 2019, 2020, 2021,
2022, 2023) must be installed.
Python_ >= 3.9 and GROMACS_ (4.6.x, 2016, 2018, 2019, 2020, 2021,
2022, 2023, 2024) must be installed.

.. _Python: http://www.python.org


System requirements
-------------------

Tested with Python 3.8--3.12 on Linux and Mac OS X. Earlier Python
Tested with Python 3.9--3.12 on Linux and Mac OS X. Earlier Python
versions were only supported until release 0.8.5.


Expand Down
3 changes: 2 additions & 1 deletion gromacs/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,8 @@
#: the commit ID encoded in the trailing string.
#:
#: .. _`semantic versioning`: https://semver.org/
__version__ = _version.get_versions()["version"]
__version__ = _version.__version__
del _version

from . import fileformats
from .exceptions import (
Expand Down
Loading

0 comments on commit 5619cca

Please sign in to comment.