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

Fold in bug fixes #34

Merged
merged 5 commits into from
May 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion fuji_server/data/software_file.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@
"parse": "full",
"pattern": [
"(\\w*/)*LICEN(S|C)E(\\.\\w*)?",
"(\\w*/)*licen(s|c)e(\\.\\w*)?"
"(\\w*/)*licen(s|c)e(\\.\\w*)?",
"(\\w*/)*COPYING"
]
},
"maven_pom": {
Expand Down
10 changes: 5 additions & 5 deletions fuji_server/evaluators/fair_evaluator_license_file.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,15 @@ def setLicenseDataAndOutput(self):
self.license_info = []
# check for any recognised license files
parsed_license_file_data = self.fuji.github_data.get("license_file")
if parsed_license_file_data is not None and len(parsed_license_file_data) > 0:
license_file_paths = [lf["path"] for lf in parsed_license_file_data]
metadata_license = self.fuji.github_data.get("license")
metadata_license_path = self.fuji.github_data.get("license_path")
recognised_licenses = []
if metadata_license is not None:
for lfp in license_file_paths: # only use metadata information if it matches a license file
if lfp == metadata_license_path:
recognised_licenses.append(metadata_license)
if parsed_license_file_data is not None and len(parsed_license_file_data) > 0:
license_file_paths = [lf["path"] for lf in parsed_license_file_data]
for lfp in license_file_paths: # only use metadata information if it matches a license file
if lfp == metadata_license_path:
recognised_licenses.append(metadata_license)
if recognised_licenses is not None and recognised_licenses != []:
for license in recognised_licenses:
isurl = False
Expand Down
Loading