appliedAI-Initiative / pymetrius

A fire-tested template for production grade python libraries and packages.
MIT License
14 stars 2 forks source link

Use deprecation package #9

Open mdbenito opened 1 year ago

mdbenito commented 1 year ago

Make it a dependency, and check in the release script that no deprecated methods are left behind in a release. deprecation allows marking the moment something is tagged for deprecation and the release at which it will be removed, e.g.

@deprecated(
    deprecated_in="0.6.0",
    removed_in="0.7.0",
    details="This class has been renamed. Use StandardErrorRatio instead",
)
class StandardError(StandardErrorRatio):
    pass
MischaPanch commented 8 months ago

I don't think this needs to be part of a template. Users can add it themselves if they want to, right?

mdbenito commented 7 months ago

Maybe you are right. My reasoning was that if pymetrius is for libraries, then every instantiation of pymetrius will need this package because careful deprecation is a must for every library. It took me a while to realize that the other only alternative, pydeprecate, was not good enough (for reasons I have already forgotten), so I thought it might save others some time to know about it.