The return value of hash() has never been guaranteed to be stable. The return value of hash() was originally defined as a standard C long. On Unix/Linux systems, a C long is (usually) 32 bits on a 32 bit system and is (usually) 64 bits on a 64 bits. A C long is always 32 bits on Windows, even on a 64-bit version of Windows. Beginning with Python 3.2, the underlying C type was changed to also be 64 bits on 64-bit Windows. A new algorithm for calculating the hash of numeric values was also introduced in Python 3.2.

A randomization feature was added to the hashing algorithm to protect against denial-of-service attacks. The randomization is off by default in the security releases of older versions but will be enabled by default in Python 3.4. The results of hash() will change with every invocation of the Python 3.4 interpreter.

If you want a stable hash function, use the functions defined in the hashlib module.