RDFLib/FuXi — pull request #6 by drewp (2014-02-17 05:45:18+00:00)
Title: HashablePatternList bug: when a rule has a Literal with whitespace in it, rdflib logs warnings

See my post at https://groups.google.com/forum/#!topic/fuxi-discussion/43arTZCbSPo for more context and demo. This __hash__ rewrite lets hash() do the mixing of the values instead of ever using +, which should perform faster and avoid the original bug. However, this will make some things that hashed the same before now have different hash values (and vice versa, in even rarer cases).

Using hash results to test equality is a bad practice in the first place, but I don't know the code well enough to fix that. It SEEMS like __eq__ should be comparing the incoming 'items' values, after whatever canonicalization (sorting, ignore bnodes, etc) is supposed to happen.