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

DM-41049: Allow derived types in ConfigDictField items #107

Closed
wants to merge 4 commits into from

Conversation

taranu
Copy link

@taranu taranu commented Nov 7, 2023

Checklist

  • ran Jenkins
  • added a release note for user-visible changes to doc/changes

Copy link

codecov bot commented Nov 7, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (ba4ed39) 85.37% compared to head (ac50554) 85.38%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #107      +/-   ##
==========================================
+ Coverage   85.37%   85.38%   +0.01%     
==========================================
  Files          46       46              
  Lines        3631     3634       +3     
==========================================
+ Hits         3100     3103       +3     
  Misses        531      531              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@@ -76,7 +76,7 @@ def __setitem__(self, k, x, at=None, label="setitem", setHistory=True):
if x == dtype:
self._dict[k] = dtype(__name=name, __at=at, __label=label)
else:
self._dict[k] = dtype(__name=name, __at=at, __label=label, **x._storage)
self._dict[k] = x.__class__(__name=name, __at=at, __label=label, **x._storage)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why did you use __class__ here instead of type?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't remember having a good reason so I changed it to type.

@taranu
Copy link
Author

taranu commented Mar 20, 2024

@natelust and @TallJimbo convinced me that supporting derived types in Config*Field would be too disruptive of a change, so I'm moving the useful parts from this ticket (updated tests, error messages, etc) to DM-43415.

@taranu taranu closed this Mar 20, 2024
@taranu taranu deleted the tickets/DM-41049 branch March 20, 2024 22:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants