Skip to content

Commit

Permalink
🐛(ozi-new interactive): fix missing license suggestions
Browse files Browse the repository at this point in the history
Signed-off-by: rjdbcm <[email protected]>
  • Loading branch information
rjdbcm committed Jun 29, 2024
1 parent 54866ed commit 21e0a4a
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
1 change: 1 addition & 0 deletions ozi/new/validate.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@ def valid_license(_license: str, license_expression: str) -> str:
)
if (
_license in iter(METADATA.spec.python.pkg.license.ambiguous)
and len(METADATA.spec.python.pkg.license.ambiguous[_license]) > 1
and license_expression.split(' ')[0] not in possible_spdx
): # pragma: no cover
TAP.diagnostic('ambiguous license')
Expand Down
22 changes: 22 additions & 0 deletions ozi/spec/_license.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,16 @@
'BSD-3-Clause-Clear',
'BSD-4-Clause',
),
'OSI Approved :: Boost Software License 1.0 (BSL-1.0)': ('BSL-1.0',),
'OSI Approved :: CEA CNRS Inria Logiciel Libre License, version 2.1 (CeCILL-2.1)': (
'CeCILL-2.1',
),
'OSI Approved :: Eclipse Public License 1.0 (EPL-1.0)': ('EPL-1.0',),
'OSI Approved :: Eclipse Public License 2.0 (EPL-2.0)': ('EPL-2.0',),
'OSI Approved :: Eiffel Forum License': ('EFL-2.0',),
'OSI Approved :: European Union Public Licence 1.0 (EUPL 1.0)': ('EUPL 1.0',),
'OSI Approved :: European Union Public Licence 1.1 (EUPL 1.1)': ('EUPL 1.1',),
'OSI Approved :: European Union Public Licence 1.2 (EUPL 1.2)': ('EUPL 1.2',),
'OSI Approved :: GNU Affero General Public License v3': (
'AGPL-3.0-only',
'AGPL-3.0-or-later',
Expand Down Expand Up @@ -173,7 +183,19 @@
'LGPL-3.0-only',
'LGPL-3.0-or-later',
),
'OSI Approved :: ISC License (ISCL)': ('ISC',),
'OSI Approved :: MIT License': ('MIT', 'MIT-0'),
'OSI Approved :: MIT No Attribution License (MIT-0)': ('MIT-0',),
'OSI Approved :: Mozilla Public License 2.0 (MPL 2.0)': ('MPL-2.0',),
'OSI Approved :: Mulan Permissive Software License v2 (MulanPSL-2.0)': ('MulanPSL-2.0',),
'OSI Approved :: Open Software License 3.0 (OSL-3.0)': ('OSL-3.0',),
'OSI Approved :: PostgreSQL License': ('PostgreSQL',),
'OSI Approved :: SIL Open Font License 1.1 (OFL-1.1)': ('OFL-1.1',),
'OSI Approved :: University of Illinois/NCSA Open Source License': ('NCSA',),
'OSI Approved :: Zero-Clause BSD (0BSD)': ('0BSD',),
'OSI Approved :: The Unlicense (Unlicense)': ('Unlicense',),
'OSI Approved :: zlib/libpng License': ('zlib',),
'Other/Proprietary License': ('LicenseRef-Proprietary',),
'Public Domain': ('LicenseRef-Public-Domain', 'Unlicense', 'CC0-1.0'),
}
SPDX_LICENSE_EXCEPTIONS = (
Expand Down

0 comments on commit 21e0a4a

Please sign in to comment.