Skip to content

Conversation

@ARMmaster17
Copy link
Owner

Summary

This PR fixes an issue where if someone put an object inside a DataContext and then later split the context, the context splitter would only perform a shallow copy, meaning that modifications to the object would be shared across all contexts for that step.

The issue is resolved in this PR by performing a deep copy. A regression test has also been added to ensure that this bug does not appear again.

Closes #6

@ARMmaster17 ARMmaster17 added the bug Something isn't working label Apr 15, 2022
@ARMmaster17 ARMmaster17 self-assigned this Apr 15, 2022
@github-actions
Copy link

github-actions bot commented Apr 15, 2022

Unit Test Results

  28 files  +2    28 suites  +2   0s ⏱️ ±0s
  56 tests +1    56 ✔️ +1  0 💤 ±0  0 ±0 
112 runs  +2  112 ✔️ +2  0 💤 ±0  0 ±0 

Results for commit 872cb4f. ± Comparison against base commit 0e29f17.

♻️ This comment has been updated with latest results.

@qlty-cloud-legacy
Copy link

Code Climate has analyzed commit 872cb4f and detected 0 issues on this pull request.

The test coverage on the diff in this pull request is 100.0% (50% is the threshold).

This pull request will bring the total coverage in the repository to 67.6% (0.5% change).

View more on Code Climate.

@ARMmaster17 ARMmaster17 merged commit 77e5755 into main Apr 15, 2022
@ARMmaster17 ARMmaster17 deleted the 6-nested-dictionarylist-objects-in-context-are-shared-across-context-splits branch April 15, 2022 01:00
@ARMmaster17 ARMmaster17 added this to the 1.1.0 milestone May 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Nested dictionary/list objects in context are shared across context splits

2 participants