clearlydefined / clearlydefined/crawler
[pypi] spdxcorrect is too aggressive for declaredLicense
- Dominant language
- JavaScript
- Stars
- 60
- Forks
- 38
- Avg merge
- 1h 49m
- Merged PRs (30d)
- 1
Description
at https://github.com/clearlydefined/crawler/blob/master/providers/fetch/pypiFetch.js#L77
```js
_extractDeclaredLicense(registryData) {
const classifiers = get(registryData, 'info.classifiers')
if (!classifiers) return null
for (const classifier in classifiers) {
if (classifiers[classifier].includes('License :: OSI Approved ::')) {
const lastColon = classifiers[classifier].lastIndexOf(':')
const rawLicense = classifiers[classifier].slice(lastColon + 1)
return spdxCorrect(rawLicense)
}
}
return null
}
```
For example https://pypi.org/pypi/Flask/json
looks at info.classifiers and pulls out
```
"License :: OSI Approved :: BSD License",
```
runs spdx-correct on `BSD License` => `BSD-2-Clause`
when it should be `BSD-3-Clause`
We should probably drop this from the crawler side entirely and let the summarizers parse the data without spdx correct
Contributor guide
Assessment
This issue has not been assessed yet.