Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

bpo-11063: Create _uuid1 submodule#3795

New issue

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

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Closed
vstinner wants to merge3 commits intopython:masterfromvstinner:uuid1
Closed

bpo-11063: Create _uuid1 submodule#3795

vstinner wants to merge3 commits intopython:masterfromvstinner:uuid1

Conversation

@vstinner
Copy link
Member

@vstinnervstinner commentedSep 28, 2017
edited by bedevere-bot
Loading

uuid module: move getnode() and uuid1() implementations to a new
_uuid1 submodule which is now loaded on demand to reduce side effects
on "import uuid".

https://bugs.python.org/issue11063

uuid module: move getnode() and uuid1() implementations to a new_uuid1 submodule which is now loaded on demand to reduce side effectson "import uuid".
@vstinner
Copy link
MemberAuthor

_unixdll_getnode() and _windll_getnode() functions used UUID(bytes=bytes).node to convert bytes to a UUID object, then to get the node. I added a new "def _bytes_to_node(rawbytes):" helper function to break the dependency from _uuid1 to the uuid.UUID class. IMHO _bytes_to_node() is simple enough to justify the "duplication" of the code.

@gronke
Copy link
Contributor

@Haypo have you noticed#3684 ? You're addressing a similar problem and your comment's are welcome! Personally I don't see a benefit from breaking uuid in two separate files. Instead we could move all code paths involved in uuid1() together. I'll comment on the other PR why we didn't.

@vstinner
Copy link
MemberAuthor

Abandonned in favor of@pitrou's PR#3796.

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

5 participants

@vstinner@gronke@Mariatta@the-knights-who-say-ni@bedevere-bot

[8]ページ先頭

©2009-2025 Movatter.jp