开发者

Unique user ID in a Pylons web application

开发者 https://www.devze.com 2022-12-26 19:02 出处:网络
What is the best way 开发者_开发技巧to create a unique user ID in Python, using UUID?I\'d go with uuid

What is the best way 开发者_开发技巧to create a unique user ID in Python, using UUID?


I'd go with uuid

from uuid import uuid4
def new_user_id():
    return uuid4().hex
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号