Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can we remove the requirement for license headers? #113

Closed
tylerbenson opened this issue Jun 14, 2019 · 21 comments · Fixed by #482
Closed

Can we remove the requirement for license headers? #113

tylerbenson opened this issue Jun 14, 2019 · 21 comments · Fixed by #482
Assignees

Comments

@tylerbenson
Copy link
Member

The license should already be defined at the root of each project, does each file really need such documentation as well?

Removing the headers would also make it much less hassle to update the license and copyright date when needed, since it would only need to be done in a single place.

@bogdandrutu
Copy link
Member

I am not a lawyer so I cannot answer this question :(. I will ask around.

@SergeyKanzhelev
Copy link
Member

here is quote from the license:

community/LICENSE

Lines 178 to 201 in b6ff37b

APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

So I think it's required. @bogdandrutu let me know if you need help and I can ask layers in MS.

@bhs
Copy link
Contributor

bhs commented Jun 14, 2019

I'm going to ask a CNCF lawyerly person to comment on whether it's literally required or "just a recommended practice". If the latter, I am in agreement with @tylerbenson that it's a bunch of wasteful boilerplate that would be wonderful to remove :)

@caniszczyk
Copy link

It's not required but strongly recommended, it makes life easier for adoption and automated tooling which discovers license information.

The minimum should at least a line with an SPDX.org id... so "// Copyright 2019 OpenTelemetry Contributions, Licensed under Apache-2.0"

@tylerbenson
Copy link
Member Author

@caniszczyk a single line is MUCH better. I can accept that as a reasonable tradeoff even if some of the benefits I mentioned above would be invalidated.

@bhs How do we make the "single line attribution" the official policy?

@bogdandrutu
Copy link
Member

Let me also double check with one lawyer from Google, I would suggest Microsoft do the same and any other company that may have some requirements. If no concerns from anyone then we should make it official. I would suggest to chat about this in the next board meeting.

@iredelmeier
Copy link
Member

@caniszczyk is there specific tooling in mind? The license tools I've seen and used generally work well with a LICENSE file. However, I've obviously only seen a small subset of what's out there!

Also, how does this policy apply across file types? e.g., do Markdown files (the spec, docs, etc.) also need the header? What about if/when we end up with JSON files, which don't allow comments at all?

@tylerbenson @bhs I imagine that there's tooling out there for checking files, i.e., as a CI check.

Related to that, we should be able to set something up (a CI job) to automatically add whatever header where it's missing. However, I can imagine some UX issues, e.g., PRs would need to allow external edits.

@yurishkuro
Copy link
Member

Governance committee recommendation:

@bogdandrutu
Copy link
Member

Can we make this official by adding this to some contribution rules md file?

@carlosalberto
Copy link
Contributor

I support @yurishkuro's suggestion, given the CNCF recommendation.

@tedsuo
Copy link
Contributor

tedsuo commented Apr 24, 2020

Following up on this. I will propose a clause to https://github.com/open-telemetry/community/blob/master/CONTRIBUTING.md stating that:

  1. All code written for this project, or donated to this project, will have a single line license header, which reads:
 // Copyright 2019 OpenTelemetry Contributions, Licensed under Apache-2.0
  1. This rule does not apply to 3rd party code copied from projects not affiliated with OpenTelemetry. Licenses and headers must be retained for all code not donated with the consent of a member organization.

I'm not a lawyer, and I am sure questions like "what does consent mean?" are the next step in this journey... but I will create a basic PR just to get it moving.

@carlosalberto
Copy link
Contributor

@tedsuo Do we really need to keep the year in the copyright? It would be nice to remove that requirement if possible ;)

@yurishkuro
Copy link
Member

We already have Governance Committee decision/recommendation #113 (comment). It matches CNCF recommendations and the wildly accepted use of Apache license. Why do we need to diverge from it by replacing headers with one line?

@tedsuo
Copy link
Contributor

tedsuo commented Apr 24, 2020

@yurishkuro Apache Foundation also recommends this shorter header: http://www.apache.org/foundation/license-faq.html#Apply-My-Software

A shorter variant you may wish to use is:

Copyright [yyyy] [name of copyright owner]
SPDX-License-Identifier: Apache-2.0

@andrewhsu
Copy link
Member

I think it is important to note that this issue was opened by @tylerbenson who is employed by DataDog. I think the resolution of this issue will help unblock open-telemetry/opentelemetry-go-contrib#15.

@tylerbenson
Copy link
Member Author

I suggested this purely out of desire to reduce visual clutter in the codebase, not because of any ulterior motive. I hate seeing PRs filled with just license headers. To that end, I would support either a single top level license file or the short 2 line license above each file. A 10 line header is excessive.

@yurishkuro
Copy link
Member

Using the two-line header recommended by Apache is fine.

@bogdandrutu
Copy link
Member

@yurishkuro can we close this issue with the following recommendation?

  • Can use the full license headers with/without the year
  • Can use the two-line header recommended by Apache with/without year

@SergeyKanzhelev
Copy link
Member

Can you pls add a few words in this section: https://github.com/open-telemetry/community#license

@tigrannajaryan
Copy link
Member

@SergeyKanzhelev I just filed this #479 which adds a link to CNCF recommendations. I can it move to https://github.com/open-telemetry/community#license section if it is a better place for the link.

In addition to that we can clarify our choices further since CNCF allows for a few alternates for copyright headers.

@SergeyKanzhelev
Copy link
Member

headers concerns both - license and copyright. So I think we need to extend the license section as well to talk about the headers. Or maybe merge these two section into "License and copyright"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.