You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I encounter this error: Invalid purl: version must be percent-encoded when parse the purl pkg:npm/@vue/vue-loader-v15@15.11.1 with method PackageURL.fromString().
This purl was validated successfully by other library mvn:packageurl-java@1.4.1 in the backend.
When I look into the code of packageurl-js, I see this:
if (p.includes('@')) {
let f = p.indexOf('@'),
u = p.substring(f + 1)
a = decodeURIComponent(u)
let y = encodeURIComponent(a).replace(/%3A/g, ':').replace(/%2B/g, '+')
if (u !== y)
throw new Error('Invalid purl: version must be percent-encoded')
i = p.substring(0, f)
}
I think it could have an issue because method indexOf() return the first matched index, but in this case pkg:npm/@vue/vue-loader-v15@15.11.1, it has another @ so f+1 is not the start of version substring.
The text was updated successfully, but these errors were encountered:
Hi, I encounter this error: Invalid purl: version must be percent-encoded when parse the purl
pkg:npm/@vue/vue-loader-v15@15.11.1
with methodPackageURL.fromString()
.This purl was validated successfully by other library mvn:packageurl-java@1.4.1 in the backend.
When I look into the code of packageurl-js, I see this:
I think it could have an issue because method indexOf() return the first matched index, but in this case
pkg:npm/@vue/vue-loader-v15@15.11.1
, it has another @ so f+1 is not the start of version substring.The text was updated successfully, but these errors were encountered: