Skip to content
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

[Feature Request] Modify decorator implementation #22

Open
1 task done
dandansamax opened this issue Aug 29, 2024 · 0 comments
Open
1 task done

[Feature Request] Modify decorator implementation #22

dandansamax opened this issue Aug 29, 2024 · 0 comments
Assignees
Labels
core Models, pipeline changing to CRAB core enhancement New feature or request

Comments

@dandansamax
Copy link
Collaborator

Required prerequisites

  • I have searched the Issue Tracker that this hasn't already been reported. (+1 or comment there if it has.)

Motivation

Current decorator implementation will change all functions to Action instances during module loading. This implementation is waste of time and counter normal python rules (The decorators shouldn't modify function behavior), which will confuse new contributors.

Solution

  • Change the decorator behavior to register rather than directly change the original function behavior
  • Mark old action decorator as deprecated
  • Use an object-oriented way to manage actions

Additional context

No response

@dandansamax dandansamax added enhancement New feature or request core Models, pipeline changing to CRAB core labels Aug 29, 2024
@dandansamax dandansamax self-assigned this Aug 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Models, pipeline changing to CRAB core enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant