classification
Title: Python uuids may not be persistent across time
Type: behavior Stage: resolved
Components: Library (Lib) Versions: Python 3.7, Python 3.6, Python 2.7
process
Status: closed Resolution: not a bug
Dependencies: Superseder:
Assigned To: Nosy List: barry, ned.deily, serhiy.storchaka, vstinner, xdegaye
Priority: normal Keywords:

Created on 2017-12-02 15:44 by xdegaye, last changed 2017-12-02 16:02 by xdegaye. This issue is now closed.

Messages (2)
msg307435 - (view) Author: Xavier de Gaye (xdegaye) * (Python triager) Date: 2017-12-02 15:44
UUIDs are unique and persistent across time and space.

UUIDs generated using the getnode() function of the uuid module on a plaform where getnode() cannot use the MAC address are based on a random number created for that purpose and are therefore transient and only valid during the life time of the python process. This seems to be a bug.

My understanding of RFC 4122 is that in that case, the random number is generated only once, otherwise the usefulness of this method is not obvious. In any case the user should be made aware of the transientness of the result of getnode() since persistency is a key feature of UUIDs.
msg307437 - (view) Author: Xavier de Gaye (xdegaye) * (Python triager) Date: 2017-12-02 16:02
Hum, I misunderstood the meaning of persistency in this context. It is the uniqueness that is persistent. Sorry for the noise, closing now.
History
Date User Action Args
2017-12-02 16:02:05xdegayesetstatus: open -> closed
resolution: not a bug
messages: + msg307437

stage: resolved
2017-12-02 15:44:11xdegayecreate