Updated Subject._subject_copy_helper to unpack the dictionary of attributes rather than passing it directly. This means that a subclass of Subject will correctly read any keyword arguments in the dict rather than passing the entire unpacked dict to the first argument.
test_copy_subclass has been extended to test that this works properly. The dummy subclass now has two attributes.
Checklist
[x] I have read the CONTRIBUTING docs and have a developer setup (especially important are pre-commitand pytest)
[x] Non-breaking change (would not break existing functionality)
[ ] Breaking change (would cause existing functionality to change)
[x] Tests added or modified to cover the changes
[x] Integration tests passed locally by running pytest
[ ] In-line docstrings updated
[ ] Documentation updated, tested running make html inside the docs/ folder
Fixes #1181.
Updated Subject._subject_copy_helper to unpack the dictionary of attributes rather than passing it directly. This means that a subclass of Subject will correctly read any keyword arguments in the dict rather than passing the entire unpacked dict to the first argument.
test_copy_subclass has been extended to test that this works properly. The dummy subclass now has two attributes.
Checklist
CONTRIBUTING
docs and have a developer setup (especially important arepre-commit
andpytest
)pytest
make html
inside thedocs/
folder