-
-
Notifications
You must be signed in to change notification settings - Fork 226
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
Add Ignore Iterable Order Option to DeepHash #403
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @bmorck
Thanks for the PR!
Can you please also update the documentation at docs/deephash_doc.rst
?
deepdiff/deephash.py
Outdated
@@ -190,6 +191,7 @@ def __init__(self, | |||
self.ignore_private_variables = ignore_private_variables | |||
self.encodings = encodings | |||
self.ignore_encoding_errors = ignore_encoding_errors | |||
self.ignore_list_order = ignore_list_order |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please rename this to ignore_iterable_order
to keep it consistent with the rest of parameter names in DeepDiff.
@seperman Thanks for the review! Just updated the PR based on your comments |
Hi @bmorck |
Codecov Report
❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more. @@ Coverage Diff @@
## dev #403 +/- ##
=======================================
Coverage 98.71% 98.71%
=======================================
Files 14 14
Lines 3257 3260 +3
=======================================
+ Hits 3215 3218 +3
Misses 42 42
|
@bmorck Thanks for contributing to DeepDiff |
This changes adds a new
ignore_iterable_order
option to the DeepHash class that allows users to specify whether lists should be sorted or not prior to the hash being computed. By default the option is set to True which preserves existing behavior.A new test (
test_ignore_iterable_order
) for this option as been added totests/test_hash.py
.This also addresses #361