-
Notifications
You must be signed in to change notification settings - Fork 57
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
Use Reuse for the license #422
base: develop
Are you sure you want to change the base?
Conversation
fedora_messaging/__init__.py
Outdated
# You should have received a copy of the GNU General Public License along | ||
# with this program; if not, write to the Free Software Foundation, Inc., | ||
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. | ||
/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is C/Javascript-style comments. In Python comments start with a #
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My apologies, i will amend it.
fedora_messaging/__init__.py
Outdated
/* | ||
* SPDX-FileCopyrightText: 2024 Red Hat, Inc | ||
* | ||
* SPDX-License-Identifier: GPL-3.0-or-later |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The license is actually GPL-2.0-or-later
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
okay, although someone asked what version of GPL you preferred and you said GPL-3.0-or-later, that's why i made use of it .
so which do you prefer i make use of?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's not change the license from what it was before, even though I would prefer GPL-3.0-or-later, the code is currently under GPL-2.0-or-later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alright, I'll update it to GPL-2.0-or-later.
fc26af7
to
6849d35
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR is lacking the Reuse check itself. You can for example use this block in .pre-commit-config.yml
:
- repo: https://github.com/fsfe/reuse-tool
rev: v5.0.2
hooks:
- id: reuse
@@ -2,7 +2,7 @@ | |||
# | |||
# This program is free software; you can redistribute it and/or modify | |||
# it under the terms of the GNU General Public License as published by | |||
# the Free Software Foundation; either version 2 of the License, or | |||
# the Free Software Foundation; either version 3 of the License, or |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is still changing the license. By the way, if you start using the SPDX-License-Identifier
tag, you can drop this block of text.
b5a591a
to
ec2069c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some more comments, mostly related to using a REUSE.toml file.
tests/integration/test_cli.py
Outdated
@@ -1,19 +1,8 @@ | |||
# This file is part of fedora_messaging. | |||
# Copyright (C) 2019 Red Hat, Inc. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can drop this line as well.
@@ -1 +1,4 @@ | |||
SPDX-FileCopyrightText: 2024 Red Hat, Inc | |||
SPDX-License-Identifier: GPL-2.0-or-later |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This does not make sense for a test fixture, I would add the fixtures to a block in a REUSE.toml file, using a wildcard, such as:
# Test fixtures
[[annotations]]
path = ["tests/fixtures/*"]
SPDX-FileCopyrightText = "2024 Red Hat, Inc"
SPDX-License-Identifier = "GPL-2.0-or-later"
This applies to all the files in this directory.
pyproject.toml
Outdated
[tool.poetry] | ||
name = "fedora_messaging" | ||
version = "3.6.0" | ||
description = "A set of tools for using Fedora's messaging infrastructure" | ||
authors = [ | ||
"Fedora Infrastructure <[email protected]>" | ||
] | ||
license = "GPLv2+" | ||
license = "GPLv3+" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please don't change the license.
pyproject.toml
Outdated
@@ -1,11 +1,15 @@ | |||
# SPDX-FileCopyrightText: 2024 Red Hat, Inc | |||
# | |||
# SPDX-License-Identifier: GPL-2.0-or-later |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It does not make much sense in the case of this file, because we're talking about project configuration here.
I would add these files to a block in a REUSE.toml file, such as:
# Project configuration
[[annotations]]
path = ["pyproject.toml", "poetry.lock", "codecov.yml", ".*.yml", ".*.yaml", "CODEOWNERS"]
SPDX-FileCopyrightText = "2024 Red Hat, Inc"
SPDX-License-Identifier = "GPL-2.0-or-later"
fedora_messaging/twisted/consumer.py
Outdated
@@ -1,20 +1,7 @@ | |||
# This file is part of fedora_messaging. | |||
# Copyright (C) 2019 Red Hat, Inc. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can be dropped as well.
docs/schema-packages.txt
Outdated
SPDX-FileCopyrightText: 2024 Red Hat, Inc | ||
SPDX-License-Identifier: GPL-2.0-or-later |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add the hash sign at the beginning of those lines to mark them as comments.
configs/cacert.pem.license
Outdated
@@ -0,0 +1,3 @@ | |||
SPDX-FileCopyrightText: 2024 Red Hat, Inc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All the files in configs
can also be covered by a block in a REUSE.toml file, such as:
# configs
[[annotations]]
path = ["configs/*"]
SPDX-FileCopyrightText = "2024 Red Hat, Inc"
SPDX-License-Identifier = "GPL-2.0-or-later"
.fmf/version
Outdated
@@ -1 +1,4 @@ | |||
SPDX-FileCopyrightText: 2024 Red Hat, Inc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The FMF config files can be covered by a block in a REUSE.toml file, such as:
# FMF
[[annotations]]
path = [".fmf/version", "packit/installation/*.fmf"]
SPDX-FileCopyrightText = "2024 Red Hat, Inc"
SPDX-License-Identifier = "GPL-2.0-or-later"
hello, i've made the changes as requested but when i run
|
Yes, you can use a REUSE.toml file to cover those files, as indicated in the comments. I don't see it, maybe you forgot to add it to the repo with |
I'm surprised as well. i thought i did cause usually i |
ec2069c
to
f295e35
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some duplication between inline changes and REUSE.toml
, and a couple comments about usage of wildcards.
REUSE.toml
Outdated
[[annotations]] | ||
path = ["tests/fixtures/bad_cb"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["tests/fixtures/ca_bundle.pem.license"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["tests/fixtures/cert.pem.license"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["tests/fixtures/good_msg_dump.txt"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["tests/fixtures/invalid_ca.pem.license"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["tests/fixtures/invalid_key.pem.license"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["tests/fixtures/invalid_msg_dump.txt"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["tests/fixtures/key.pem.license"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["tests/fixtures/msg_without_topic_dump.txt"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["tests/fixtures/wrong_json_msg_dump.txt"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["tests/fixtures/ca_bundle.pem"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["tests/fixtures/cert.pem"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["tests/fixtures/key.pem"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You could actually use a wildcard here: tests/fixtures/*
. This will make the file much more readable.
CODEOWNERS
Outdated
# SPDX-FileCopyrightText: 2024 Red Hat, Inc | ||
# | ||
# SPDX-License-Identifier: GPL-2.0-or-later | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You no longer need this since you have flagged this file in REUSE.toml
.
@@ -1,339 +1,205 @@ | |||
GNU GENERAL PUBLIC LICENSE | |||
Version 2, June 1991 | |||
|
|||
Copyright (C) 1989, 1991 Free Software Foundation, Inc., |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can actually delete this file, it's replaced by the one in the LICENSES
directory.
poetry.lock.license
Outdated
@@ -0,0 +1,3 @@ | |||
SPDX-FileCopyrightText: 2024 Red Hat, Inc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You don't need this file since you flagged poetry.lock
in REUSE.toml
.
REUSE.toml
Outdated
path = ["configs/cacert.pem.license"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["configs/fedora-cert.pem.license"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["configs/fedora-key.pem.license"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["configs/fedora.stg-cert.pem.license"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["configs/fedora.stg-key.pem.license"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["configs/stg-cacert.pem.license"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["configs/cacert.pem"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["configs/fedora-cert.pem"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["configs/fedora-key.pem"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["configs/fedora.stg-cert.pem"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["configs/fedora.stg-key.pem"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" | ||
|
||
[[annotations]] | ||
path = ["configs/stg-cacert.pem"] | ||
SPDX-FileCopyrightText = "2024 Red Hat, Inc" | ||
SPDX-License-Identifier = "GPL-2.0-or-later" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can use a wildcard in the path here as well: configs/*
codecov.yml
Outdated
# SPDX-FileCopyrightText: 2024 Red Hat, Inc | ||
# | ||
# SPDX-License-Identifier: GPL-2.0-or-later | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You don't need this since you flagged the file in REUSE.toml
.
packit/installation/main.fmf
Outdated
@@ -1,3 +1,6 @@ | |||
SPDX-FileCopyrightText: 2024 Red Hat, Inc | |||
SPDX-License-Identifier: GPL-2.0-or-later | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now that you've added it to REUSE.toml
, you can drop this change.
tests/fixtures/bad_conf.toml
Outdated
# SPDX-FileCopyrightText: 2024 Red Hat, Inc | ||
# | ||
# SPDX-License-Identifier: GPL-2.0-or-later | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The files in this directory have been added to REUSE.toml
, no need for these changes anymore.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can remove the files in configs/*.license
and tests/fixtures/*.license
now, since the corresponding files are now covered in REUSE.toml
.
8de426f
to
6321105
Compare
.pre-commit-config.yaml
Outdated
@@ -24,7 +28,7 @@ repos: | |||
# Ruff | |||
- repo: https://github.com/charliermarsh/ruff-pre-commit | |||
# Ruff version. | |||
rev: v0.8.6 | |||
rev: v0.8.2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This does not seem necessary, maybe a rebase fallout.
news/383.docs.md
Outdated
@@ -0,0 +1,7 @@ | |||
<!-- |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment is still current.
@@ -1 +1,2 @@ | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think you need to add an empty line here.
6321105
to
0816fbf
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can also remove the news/*.license
files as they are covered by REUSE.toml
.
.packit.yaml
Outdated
@@ -1,3 +1,7 @@ | |||
# SPDX-FileCopyrightText: 2024 Red Hat, Inc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file is already covered by the .*.yaml
glob in REUSE.toml
.
.pre-commit-config.yaml
Outdated
@@ -1,3 +1,7 @@ | |||
# SPDX-FileCopyrightText: 2024 Red Hat, Inc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file is already covered by the .*.yaml
glob in REUSE.toml
.
.readthedocs.yml
Outdated
@@ -1,3 +1,7 @@ | |||
# SPDX-FileCopyrightText: 2024 Red Hat, Inc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file is already covered by the .*.yml
glob in REUSE.toml
.
configs/fedora.stg.toml
Outdated
@@ -1,3 +1,7 @@ | |||
# SPDX-FileCopyrightText: 2024 Red Hat, Inc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file is already covered by the configs/*
glob in REUSE.toml
.
configs/fedora.toml
Outdated
@@ -1,3 +1,7 @@ | |||
# SPDX-FileCopyrightText: 2024 Red Hat, Inc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file is already covered by the configs/*
glob in REUSE.toml
.
[email protected]
Outdated
SPDX-FileCopyrightText: 2024 Red Hat, Inc | ||
SPDX-License-Identifier: GPL-2.0-or-later |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This requires a prefix comment. Systemd unit files are INI files, and therefore can use ;
or #
as a comment prefix. I would go for #
since that's what I see most of the files in /usr/lib/systemd/system
using.
SPDX-FileCopyrightText: 2024 Red Hat, Inc | |
SPDX-License-Identifier: GPL-2.0-or-later | |
# SPDX-FileCopyrightText: 2024 Red Hat, Inc | |
# SPDX-License-Identifier: GPL-2.0-or-later |
0816fbf
to
c1d1ae4
Compare
config.toml.example
Outdated
SPDX-FileCopyrightText: 2024 Red Hat, Inc | ||
SPDX-License-Identifier: GPL-2.0-or-later |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This requires a comment as well.
SPDX-FileCopyrightText: 2024 Red Hat, Inc | |
SPDX-License-Identifier: GPL-2.0-or-later | |
# SPDX-FileCopyrightText: 2024 Red Hat, Inc | |
# SPDX-License-Identifier: GPL-2.0-or-later |
docs/requirements-readthedocs.txt
Outdated
SPDX-FileCopyrightText: 2024 Red Hat, Inc | ||
SPDX-License-Identifier: GPL-2.0-or-later |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These lines must be commented out.
SPDX-FileCopyrightText: 2024 Red Hat, Inc | |
SPDX-License-Identifier: GPL-2.0-or-later | |
# SPDX-FileCopyrightText: 2024 Red Hat, Inc | |
# SPDX-License-Identifier: GPL-2.0-or-later |
docs/sample_schema_package/README
Outdated
SPDX-FileCopyrightText: 2024 Red Hat, Inc | ||
SPDX-License-Identifier: GPL-2.0-or-later | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be commented out but it's a plain text file. Maybe rename this file to .md
and add the tags in a comment, as for SECURITY.md
.
c1d1ae4
to
3479ca5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, thanks!
Could you please squash your 3 commits into one? Then it'll be good to merge.
…v0.8.6 (fedora-infra#428) Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Use Reuse for license Signed-off-by: Olamide Ojo <[email protected]>
Signed-off-by: Olamide Ojo <[email protected]>
3479ca5
to
44ddeb2
Compare
Fixes #383