-
-
Notifications
You must be signed in to change notification settings - Fork 564
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
Wrong spdx detection for file generator #2502
Comments
@tardyp thanks.
So Some solution elements:
|
hi @pombredanne thanks for detalled comments. makes a lot of sense Some comments:
LicenseRef-ACME-Proprietary is not reported as something unknown in my instance as I have custom rules that defines it.(a fix for #2471 that is not yet ready for upstream). I think this is the best way to solve it for me. This ensures that all SPDX licenses are correctly identified by the IP Management group.
I think this fits my problem and I will experiment on it for short term.
I had a similar idea, but print is not universal. what is more universal are to me are quotes
|
Yes, quotes would be better... we are mostly ignoring quotes. Except for SPDX License Identifiers, where we can access to the raw text. In https://github.com/nexB/scancode-toolkit/blob/bb044200ae86770f9bb01560c0033037ee18b947/src/licensedcode/query.py#L441 we could likely add a test on the content. If I use this one liner as a test file
we have these values to use as needed:
The mere presence of a single quote may be enough to flag this as a false positive IMHO... BUT there could be cases (such as formatted markdown?) where this may not be a false positive? |
I also have a similar issue.
Although it is not a license registered in SPDX, is there a way to print the License ID ("Sample-Proprietary" in the example above) if it is written according to the notation of the SPDX License? If "key" extracted as "unknown-spdx", how about outputting "identifier" in "matched_rule" as License ID written? |
This is not what you ask but at least if you use the option
|
Dear @pombredanne , |
Some of our files contain generator of source code.
Looks like this:
The 5th line got detected by the spdx matcher, but the detected SPDX license is unknown
We do add
LicenseRef-ACME-Proprietary
in our custom SPDX license, but it is not recognised, probably the end of the line is taken as part of the full SPDX ID.The text was updated successfully, but these errors were encountered: