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

Upgrade ImmutableStrategy #3

Open
pedrorrivero opened this issue Oct 19, 2022 · 0 comments
Open

Upgrade ImmutableStrategy #3

pedrorrivero opened this issue Oct 19, 2022 · 0 comments
Labels
DC-4 Difficulty class 4/5 → Multidomain knowledge enhancement New non-feature request (e.g. performance) PL-2 Priority level 2/5 → Medium-high

Comments

@pedrorrivero
Copy link
Member

What is the expected enhancement?

Currently, ImmutableStrategy updates __new__() and configures __repr__() to dynamically include the args passed to __init__().

There are cases, nonetheless, where we do not want some of those args to be included in repr, so exceptions have to be hardcoded into the class, forcing updates to ImmutableStrategy to create a child class. Ideally we would like to avoid this, letting the user specify which args to include and which not to.

Also, there are better ways to enforce immutability based on meta-programming concepts (e.g. __slots__, descriptors).

@pedrorrivero pedrorrivero added enhancement New non-feature request (e.g. performance) DC-4 Difficulty class 4/5 → Multidomain knowledge PL-2 Priority level 2/5 → Medium-high labels Oct 19, 2022
@pedrorrivero pedrorrivero added this to the 1.0.0 milestone Oct 19, 2022
@pedrorrivero pedrorrivero removed this from the 1.0.0 milestone Nov 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DC-4 Difficulty class 4/5 → Multidomain knowledge enhancement New non-feature request (e.g. performance) PL-2 Priority level 2/5 → Medium-high
Projects
None yet
Development

No branches or pull requests

1 participant