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

Fix license header to match Eclipse recommendations #88

Closed
carslen opened this issue Feb 20, 2023 · 7 comments · Fixed by #1029
Closed

Fix license header to match Eclipse recommendations #88

carslen opened this issue Feb 20, 2023 · 7 comments · Fixed by #1029
Labels
bug Something isn't working

Comments

@carslen
Copy link
Contributor

carslen commented Feb 20, 2023

Please fix license header in src code files to match Eclipse recommendations.

@stephanbcbauer
Copy link
Member

@florianrusch-zf I think this is already done.? There is also a new QGate check #277

@florianrusch-zf
Copy link
Contributor

@carslen maybe you can bring some clarification in. Does every file, which allows to contain comments, need to have exactly this header (copied from https://eclipse-tractusx.github.io/docs/release/trg-7/trg-7-02):

/********************************************************************************
 * Copyright (c) 2021,2023 Contributors to the Eclipse Foundation
 *
 * See the NOTICE file(s) distributed with this work for additional
 * information regarding copyright ownership.
 *
 * This program and the accompanying materials are made available under the
 * terms of the Apache License, Version 2.0 which is available at
 * https://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.
 *
 * SPDX-License-Identifier: Apache-2.0
 ********************************************************************************/

Currently we have a mix of different headers. Some headers are like the above one and others are like the following (just an example):

/*
* Copyright (c) 2023 Bayerische Motoren Werke Aktiengesellschaft (BMW AG)
*
* This program and the accompanying materials are made available under the
* terms of the Apache License, Version 2.0 which is available at
* https://www.apache.org/licenses/LICENSE-2.0
*
* SPDX-License-Identifier: Apache-2.0
*
* Contributors:
*       Bayerische Motoren Werke Aktiengesellschaft (BMW AG) - initial API and implementation
*
*/

From a legal point of view, are we allowed to simply rewrite the headers?

In addition, does any other repo already have an automated way to check within a PR if the license headers are correct?

@carslen
Copy link
Contributor Author

carslen commented Jun 14, 2023

Maybe it makes more sense to schedule a short meeting to clarify things. I'd invite @AngelikaWittek as well, as she is our FOSS expert in Eclipse-Tractusx and can shed light on this topic.

@paullatzelsperger
Copy link
Contributor

paullatzelsperger commented Jul 19, 2023

As far as I'm aware both header formats are acceptable. In addition, if the Copyright is made out to a more generic "Contributors of the Eclipse Foundation", the actual copyright ownership would be established through git commit history.

@carslen
Copy link
Contributor Author

carslen commented Jul 19, 2023

Thanks for the feedback, @paullatzelsperger.

You're right, both variants are acceptable in regards of the copyright header. If you know and add the correct copyright holder to the header for different files, then its OK. The advantage of using the "Contributors to the Eclipse Foundation" Copyright header is mentioned in the next paragraph: Check NOTICE.md and there you'll be pointed out to the git history.

Nevertheless, the short version of the license header menioned by @florianrusch-zf is not a valid Apache-2.0 license header, as the warrenty part is missing → https://spdx.org/licenses/Apache-2.0 → Standard License Header (at bottom of the page). In addition the Contributors part in the short version of the header are not nessecary and have no legal impact.

We recomment to use the long version of the license/copyright header as mentioned in TRG 7.01. If you you use the "Contributors to the Eclipse Foundation" or not is up to you, as long as you set the copyright holder appropiately.

@paullatzelsperger
Copy link
Contributor

@carslen ah, thanks for clarifying. so we should then either use the long format with the "Contributors of the...." section, or - probably even better - the exact holder(s) of the copyright?

@carslen
Copy link
Contributor Author

carslen commented Jul 20, 2023

The Apache-2.0 license header (the long one) should be applied anyway.

How you manage the copyright header is up to you and depends in a way to your contracts (e.g. if BMW insists on beeing the copyright holder of specific code), or if it could be handled more general using the "Contributors of the Eclipse Foundation" Copyright header.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

4 participants