-
Notifications
You must be signed in to change notification settings - Fork 60
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
Simple framework to port scripts into legacy #807
Conversation
Build Failed 💥 |
Hello @AlexVCaron, Thank you for updating ! There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻 Comment last updated at 2023-11-16 18:27:40 UTC |
Build Failed 💥 |
384c62a
to
ad56893
Compare
Build passed ! Good Job 🍻 ! |
Build Failed 💥 |
Build Failed 💥 |
Build Failed 💥 |
Build Failed 💥 |
Build passed ! Good Job 🍻 ! |
Tested on an upcomping branch on mine to deprecate the scil_streamline_math (already deprecated, but without the decorator). (P.S. the description of this PR should read: the decorator of the main is @deprecate_script) Works! Questions:
|
I think it would make more sense if @AlexVCaron you put scil_streamline_math script example in this PR. |
I added the script. Do we keep a long expiration window on the version major ? Or we shorten it by targeting 2 or 3 minor revisions ahead ? |
Build passed ! Good Job 🍻 ! |
Build passed ! Good Job 🍻 ! |
976c2db
to
7fcddf3
Compare
Build passed ! Good Job 🍻 ! |
Build passed ! Good Job 🍻 ! |
Build passed ! Good Job 🍻 ! |
1 similar comment
Build passed ! Good Job 🍻 ! |
Legacy scripts are added to the setup directly in version.py. We have to decide how long the use of a deprecated script remains correct. Since it is interface breaknig for our user, I would remove them when the next
major
version comes out.To port a script into legacy :
from scilpy.io.deprecator import deprecate_script
DEPRECATION_MSG = "..."
@deprecate_with_version(DEPRECATION_MSG, "<version when deprecation starts>")
For now, build will succeed even if there is outdated legacy scripts in the repository. However, they won't be executable (will raise an error by default). I will investigate in
setuptools
to find a way to do it.