Skip to content

Commit 731f3af

Browse files
authored
Merge pull request #853 from dwhswenson/deprecate_msmbuilder
Deprecate MSMBuilder
2 parents 93d43ef + 58db705 commit 731f3af

3 files changed

Lines changed: 14 additions & 2 deletions

File tree

‎devtools/optional_packages.txt‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +0,0 @@
1-
msmbuilder

‎openpathsampling/collectivevariable.py‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@
44
from openpathsampling.netcdfplus import WeakKeyCache, \
55
ObjectJSON, create_to_dict, ObjectStore, PseudoAttribute
66

7+
from openpathsampling.deprecations import (has_deprecations, deprecate,
8+
MSMBUILDER)
9+
710
import sys
811
if sys.version_info > (3, ):
912
get_code = lambda func: func.__code__
@@ -579,6 +582,8 @@ def to_dict(self):
579582
}
580583

581584

585+
@has_deprecations
586+
@deprecate(MSMBUILDER)
582587
class MSMBFeaturizerCV(CoordinateGeneratorCV):
583588
"""
584589
A CollectiveVariable that uses an MSMBuilder3 featurizer

‎openpathsampling/deprecations.py‎

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,15 @@ def version_tuple_to_string(version_tuple):
146146
deprecated_in=(0, 9 ,3)
147147
)
148148

149-
# has_deprecation and deprecate hacks to change docstrings inspired by:
149+
MSMBUILDER = Deprecation(
150+
problem=("MSMBuilder is no longer maintained. "
151+
+ "MSMBFeaturizer is no longer officially supported."),
152+
remedy="Create a CoordinateFunctionCV based on MSMBuilderFeaturizers.",
153+
remove_version=(2, 0),
154+
deprecated_in=(1, 1, 0)
155+
)
156+
157+
# has_deprecations and deprecate hacks to change docstrings inspired by:
150158
# https://stackoverflow.com/a/47441572/4205735
151159
def has_deprecations(cls):
152160
"""Decorator to ensure that docstrings get updated for wrapped class"""

0 commit comments

Comments
 (0)