Skip to content
This repository has been archived by the owner on Aug 8, 2024. It is now read-only.

BIDSLayoutDeprecationMixin? #20

Open
adelavega opened this issue Dec 12, 2022 · 2 comments
Open

BIDSLayoutDeprecationMixin? #20

adelavega opened this issue Dec 12, 2022 · 2 comments

Comments

@adelavega
Copy link
Collaborator

Would it make sense to have a BIDSLayoutDeprecationMixin which handles all of the deprecation warnings in __init__ and beyond?

This should wait until we're done w/ the refactor, but would make the code cleaner.

@erdalkaraca
Copy link
Collaborator

I think the mixin mechanism (monkey-patching in Python) can only replace/add properties of an object, but it will be hard to modify the behavior of an existing class function/method/constructor.

@adelavega
Copy link
Collaborator Author

We could do a decorator

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants