LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH] scripts/spdxcheck.py: Fix path to deprecated licenses
@ 2019-05-11 20:19 Sven Eckelmann
  2019-05-11 20:19 ` [PATCH 2/2] scripts/spdxcheck.py: Add dual license subdirectory Sven Eckelmann
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Sven Eckelmann @ 2019-05-11 20:19 UTC (permalink / raw)
  To: linux-kernel; +Cc: Sven Eckelmann, Jonathan Corbet, Christoph Hellwig

The directory name for other licenses was changed to "deprecated" in 
commit 62be257e986d ("LICENSES: Rename other to deprecated"). But it was
not changed for spdxcheck.py. As result, checkpatch failed with

  FAIL: "Blob or Tree named 'other' not found"
  Traceback (most recent call last):
    File "scripts/spdxcheck.py", line 240, in <module>
      spdx = read_spdxdata(repo)
    File "scripts/spdxcheck.py", line 41, in read_spdxdata
      for el in lictree[d].traverse():
    File "/usr/lib/python2.7/dist-packages/git/objects/tree.py", line 298, in __getitem__
      return self.join(item)
    File "/usr/lib/python2.7/dist-packages/git/objects/tree.py", line 244, in join
      raise KeyError(msg % file)
  KeyError: "Blob or Tree named 'other' not found"

Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Christoph Hellwig <hch@lst.de>
Fixes: 62be257e986d ("LICENSES: Rename other to deprecated")
Signed-off-by: Sven Eckelmann <sven@narfation.org>
---
 scripts/spdxcheck.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/spdxcheck.py b/scripts/spdxcheck.py
index 4fe392e507fb..1a39b34588b7 100755
--- a/scripts/spdxcheck.py
+++ b/scripts/spdxcheck.py
@@ -32,7 +32,7 @@ class SPDXdata(object):
 def read_spdxdata(repo):
 
     # The subdirectories of LICENSES in the kernel source
-    license_dirs = [ "preferred", "other", "exceptions" ]
+    license_dirs = [ "preferred", "deprecated", "exceptions" ]
     lictree = repo.head.commit.tree['LICENSES']
 
     spdx = SPDXdata()
-- 
2.20.1


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH 2/2] scripts/spdxcheck.py: Add dual license subdirectory
  2019-05-11 20:19 [PATCH] scripts/spdxcheck.py: Fix path to deprecated licenses Sven Eckelmann
@ 2019-05-11 20:19 ` Sven Eckelmann
  2019-05-13  6:38 ` [PATCH] scripts/spdxcheck.py: Fix path to deprecated licenses Christoph Hellwig
  2019-05-20 19:26 ` Jonathan Corbet
  2 siblings, 0 replies; 4+ messages in thread
From: Sven Eckelmann @ 2019-05-11 20:19 UTC (permalink / raw)
  To: linux-kernel; +Cc: Sven Eckelmann, Jonathan Corbet, Christoph Hellwig

The licenses from the other directory were partially moved to the dual
directory in commit 99871f2f9a4d ("scripts/spdxcheck.py: Fix path to
deprecated licenses"). checkpatch therefore rejected files like
drivers/staging/android/ashmem.h with

  WARNING: 'SPDX-License-Identifier: GPL-2.0 OR Apache-2.0 */' is not supported in LICENSES/...
  #1: FILE: drivers/staging/android/ashmem.h:1:
  +/* SPDX-License-Identifier: GPL-2.0 OR Apache-2.0 */

Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Christoph Hellwig <hch@lst.de>
Fixes: 99871f2f9a4d ("scripts/spdxcheck.py: Fix path to deprecated licenses")
Signed-off-by: Sven Eckelmann <sven@narfation.org>
---
 scripts/spdxcheck.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/spdxcheck.py b/scripts/spdxcheck.py
index 1a39b34588b7..33df646618e2 100755
--- a/scripts/spdxcheck.py
+++ b/scripts/spdxcheck.py
@@ -32,7 +32,7 @@ class SPDXdata(object):
 def read_spdxdata(repo):
 
     # The subdirectories of LICENSES in the kernel source
-    license_dirs = [ "preferred", "deprecated", "exceptions" ]
+    license_dirs = [ "preferred", "deprecated", "exceptions", "dual" ]
     lictree = repo.head.commit.tree['LICENSES']
 
     spdx = SPDXdata()
-- 
2.20.1


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] scripts/spdxcheck.py: Fix path to deprecated licenses
  2019-05-11 20:19 [PATCH] scripts/spdxcheck.py: Fix path to deprecated licenses Sven Eckelmann
  2019-05-11 20:19 ` [PATCH 2/2] scripts/spdxcheck.py: Add dual license subdirectory Sven Eckelmann
@ 2019-05-13  6:38 ` Christoph Hellwig
  2019-05-20 19:26 ` Jonathan Corbet
  2 siblings, 0 replies; 4+ messages in thread
From: Christoph Hellwig @ 2019-05-13  6:38 UTC (permalink / raw)
  To: Sven Eckelmann; +Cc: linux-kernel, Jonathan Corbet, Christoph Hellwig

For both patches:

Reviewed-by: Christoph Hellwig <hch@lst.de>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] scripts/spdxcheck.py: Fix path to deprecated licenses
  2019-05-11 20:19 [PATCH] scripts/spdxcheck.py: Fix path to deprecated licenses Sven Eckelmann
  2019-05-11 20:19 ` [PATCH 2/2] scripts/spdxcheck.py: Add dual license subdirectory Sven Eckelmann
  2019-05-13  6:38 ` [PATCH] scripts/spdxcheck.py: Fix path to deprecated licenses Christoph Hellwig
@ 2019-05-20 19:26 ` Jonathan Corbet
  2 siblings, 0 replies; 4+ messages in thread
From: Jonathan Corbet @ 2019-05-20 19:26 UTC (permalink / raw)
  To: Sven Eckelmann; +Cc: linux-kernel, Christoph Hellwig

On Sat, 11 May 2019 22:19:16 +0200
Sven Eckelmann <sven@narfation.org> wrote:

> The directory name for other licenses was changed to "deprecated" in 
> commit 62be257e986d ("LICENSES: Rename other to deprecated"). But it was
> not changed for spdxcheck.py. As result, checkpatch failed with

Both patches applied, thanks.

jon

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-05-20 19:26 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-11 20:19 [PATCH] scripts/spdxcheck.py: Fix path to deprecated licenses Sven Eckelmann
2019-05-11 20:19 ` [PATCH 2/2] scripts/spdxcheck.py: Add dual license subdirectory Sven Eckelmann
2019-05-13  6:38 ` [PATCH] scripts/spdxcheck.py: Fix path to deprecated licenses Christoph Hellwig
2019-05-20 19:26 ` Jonathan Corbet

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).