gh-95649: Document that asyncio contains uvloop code#107536
Conversation
|
As prior art (just looking through
Given that code was incorporated here, perhaps the best route is instead to add the full A |
|
(Adding the backport labels as whatever the end result is, the correct licence notices should exist in Python 3.11, where the change first appeared.) |
Already done! Although, I've just linked to the Lines 1045 to 1069 in efa45b0
We still need some information in each individual file, since CPython's But sticking the full license text in every file is very verbose and difficult to summarize. It's why the Linux kernel and lots of other OSS projects have switched to using the SPDX standard, so people can just write FYI, I'm not a lawyer, so I'm just following what other projects do, like the Linux kernel. I'm going to ping @tiran, since as the author of #95649 and python/devguide#928, they probably care the most about this subject. |
AA-Turner
left a comment
There was a problem hiding this comment.
Thanks for the update -- I realise I was unclear, I had intended to ask why we don't only include the notice in Doc/license.rst, but you've addressed my concerns. One suggestion on wording for the text in license:
Thanks!
Adam
| asyncio | ||
| ---------- | ||
|
|
||
| The :mod:`asyncio` module contains the following notice:: |
There was a problem hiding this comment.
| The :mod:`asyncio` module contains the following notice:: | |
| Parts of the :mod:`asyncio` module are incorporated from uvloop 0.16, | |
| which is distributed under the MIT license:: |
There was a problem hiding this comment.
Good idea! Changed in aloisklink@d5aee03 (I've also made the uvloop 0.16 text a hyperlink to https://github.com/MagicStack/uvloop/tree/v0.16.0)
Reword `Doc/license.rst` file, as suggested in python#107536 (comment) Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
|
@aloisklink please may you resolve the conflicts? A |
Some of the asyncio SSL changes in pythonGH-31275 were taken from [v0.16.0 of the uvloop project][1]. In order to comply with the MIT license, we need to just need to document the copyright information. [1]: https://github.com/MagicStack/uvloop/tree/v0.16.0
d5aee03 to
4b7beed
Compare
Fixed! Thanks for the reminder :) Although, I guess this means that there may now be conflicts if we backport this to Python 3.11/Python 3.12. |
|
Thanks @aloisklink for the PR, and @AA-Turner for merging it 🌮🎉.. I'm working now to backport this PR to: 3.11, 3.12. |
|
Sorry, @aloisklink and @AA-Turner, I could not cleanly backport this to |
|
Sorry, @aloisklink and @AA-Turner, I could not cleanly backport this to |
|
@aloisklink do you want to have a go at the backports? A |
…thonGH-107536) Some of the asyncio SSL changes in pythonGH-31275 [1] were taken from v0.16.0 of the uvloop project [2]. In order to comply with the MIT license, we need to just need to document the copyright information. [1]: python#31275 [2]: https://github.com/MagicStack/uvloop/tree/v0.16.0 (cherry picked from commit dce30c9) Co-authored-by: Alois Klink <alois@aloisklink.com>
…thonGH-107536) Some of the asyncio SSL changes in pythonGH-31275 [1] were taken from v0.16.0 of the uvloop project [2]. In order to comply with the MIT license, we need to just need to document the copyright information. [1]: python#31275 [2]: https://github.com/MagicStack/uvloop/tree/v0.16.0 (cherry picked from commit dce30c9)
|
GH-114045 is a backport of this pull request to the 3.11 branch. |
|
GH-114046 is a backport of this pull request to the 3.12 branch. |
… (#114045) Some of the asyncio SSL changes in GH-31275 [1] were taken from v0.16.0 of the uvloop project [2]. In order to comply with the MIT license, we need to just need to document the copyright information. [1]: #31275 [2]: https://github.com/MagicStack/uvloop/tree/v0.16.0 (cherry picked from commit dce30c9)
… (#114046) Some of the asyncio SSL changes in GH-31275 [1] were taken from v0.16.0 of the uvloop project [2]. In order to comply with the MIT license, we need to just need to document the copyright information. [1]: #31275 [2]: https://github.com/MagicStack/uvloop/tree/v0.16.0 (cherry picked from commit dce30c9)
…7536) Some of the asyncio SSL changes in pythonGH-31275 [1] were taken from v0.16.0 of the uvloop project [2]. In order to comply with the MIT license, we need to just need to document the copyright information. [1]: python#31275 [2]: https://github.com/MagicStack/uvloop/tree/v0.16.0
…7536) Some of the asyncio SSL changes in pythonGH-31275 [1] were taken from v0.16.0 of the uvloop project [2]. In order to comply with the MIT license, we need to just need to document the copyright information. [1]: python#31275 [2]: https://github.com/MagicStack/uvloop/tree/v0.16.0
…7536) Some of the asyncio SSL changes in pythonGH-31275 [1] were taken from v0.16.0 of the uvloop project [2]. In order to comply with the MIT license, we need to just need to document the copyright information. [1]: python#31275 [2]: https://github.com/MagicStack/uvloop/tree/v0.16.0
Some of the asyncio SSL changes in GH-31275 were taken from v0.16.0 of the uvloop project. In order to comply with the MIT license, we need to just need to document the copyright information.
Design decisions
How did I pick the files to add licensing info to?
I went through commit 13c10bf and added the
# SPDX-FileCopyrightText: ...for changes to any file that has substantial code taken from https://github.com/MagicStack/uvloop/tree/v0.16.0.The uvloop MIT license copyright text is
Copyright (c) 2015-present MagicStack Inc. http://magic.io, so I changed it toCopyright (c) 2015-2021 MagicStack Inc. http://magic.io, as when 13c10bf was committed, the uvloop code was last modified in 2021.Why did I use the
# SPDX-...comment format?Since there isn't yet a standard way to document licensing/copyright info (see python/devguide#928 for the issue tracking this), I've used the
# SPDX-FileCopyrightText/# SPDX-License-Identifierformat since that's the SPDX spec, which is the most common method of doing copyright/licensing information, used by Linux.Normally, we should also add a
# SPDX-FileCopyrightText: Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021, 2022, 2023 Python Software Foundation; All Rights Reservedline, but then we'd have to update the line every year, and I think theLICENSEfile already covers this.Why is there no
# Licensed to PSF under a Contributor Agreement.comment?As raised in #95649, there's no information about whether the contributor actually had the rights to relicense this code under the PSF.
Personally, the changes in
Lib/asyncioseem to come from uvloop code authored by either @asvetlov, or @MagicStack employees, so it should be pretty easy to relicense these files under the PSF, assuming @MagicStack approves. See https://github.com/MagicStack/uvloop/commits/v0.16.0/uvloop/sslproto.pyx (MagicStack/uvloop@ef29dab is by an author that isn't @MagicStack or @asvetlov, but that change is pretty trivial, so it should still be okay to relicense).However,
Lib/test/test_asyncio/test_ssl.pyseems to have a bunch of different authors from uvloop. And since there doesn't seem to be a uvloop CLA, even if @MagicStack approves, I don't think we can relicense this file under the PSF.📚 Documentation preview 📚: https://cpython-previews--107536.org.readthedocs.build/