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

Make dynamically processed args accessible to __init__. #11

Open
vahidzee opened this issue Dec 31, 2022 · 0 comments
Open

Make dynamically processed args accessible to __init__. #11

vahidzee opened this issue Dec 31, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@vahidzee
Copy link
Owner

The current implementation of dynamized __init__ separates the context for calling the original __init__ implementation, it would be very helpful to mix the two contexts so that arguments which will be added to the init later on by dycode are also accessible.

For instance:

@dy.dynamize
class MyClass:
   x = dy.field()
   def __init__(self, a, b, c, ...):
      # doing something with x should also be possible
@vahidzee vahidzee added the enhancement New feature or request label Dec 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant