Skip to content

Array position change only resulting in multiple DiffEdit events instead of DiffArray event #151

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

Closed
kaz138 opened this issue Dec 26, 2018 · 1 comment

Comments

@kaz138
Copy link

kaz138 commented Dec 26, 2018

I tested Deep-Diff on an array object that changes only the ordering of two elements, and result in multiple DiffEdit events each has a path that point to the position of the array where the change happened (instead of an DiffArray event).

Is this to be expected?

I did wish to see DiffArray event in this case because it would be easier to inteprete, since I filter to DiffArray kind for array fields currently, and this comes as a surprise that now I have to deal with the DiffEdit events but also multiple ones rather than one single diff object that has nested reports (like when adding / removing elements in the array).

@flitbit
Copy link
Collaborator

flitbit commented Jan 7, 2019

Duplicate of #37, #38, #100. I think we have enough reports on this; now I just need someone to PR a solution.

@flitbit flitbit closed this as completed Jan 7, 2019
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

No branches or pull requests

1 participant