Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Travis Failing Test Cases in Master #315

Closed
tusharmakkar08 opened this issue Dec 6, 2017 · 2 comments
Closed

Travis Failing Test Cases in Master #315

tusharmakkar08 opened this issue Dec 6, 2017 · 2 comments

Comments

@tusharmakkar08
Copy link
Collaborator

Hey

Merging of PR: #311 has resulted in tests failure in the master branch.

@dtao: Please look into this.

@dtao
Copy link
Contributor

dtao commented Dec 6, 2017

Yikes! I will take a look.

@dtao
Copy link
Contributor

dtao commented Dec 6, 2017

Hmm, so now that I'm looking into this I'm noticing that the issue seems to be that the Schema.__eq__ method just tests for string equality of two objects' schema attributes. Since ordering of keys is not deterministic for dicts, I would argue this is actually a bug (i.e. if a == Schema({'foo': 1, 'bar': 2}) and b == Schema({'foo': 1, 'bar': 2}), then a == b is non-deterministic). In which case the fix here is probably to fix the __eq__ method to be deterministic for dict-based schemas.

@alecthomas Does that sound right to you? I am happy to create a PR to fix the issue.

dtao added a commit to dtao/voluptuous that referenced this issue Dec 6, 2017
dtao added a commit to dtao/voluptuous that referenced this issue Dec 6, 2017
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants