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

License? #8

Open
solonovamax opened this issue Sep 27, 2021 · 2 comments
Open

License? #8

solonovamax opened this issue Sep 27, 2021 · 2 comments

Comments

@solonovamax
Copy link

solonovamax commented Sep 27, 2021

Where does this project stand in terms of licensing?

As per xdrop/fuzzywuzzy#35, xdrop/fuzzywuzzy#84, and xdrop/fuzzywuzzy#78, the parent project is currently licensed under GPLv2.0.

Because of this, this repo should be under GPL as well, no?

Whereas, this repo is under the Apache-2.0 license.

I'd love to use this in my project (solo-studios/PolyBot), but it is (currently) under MIT and I don't wish to step on any licenses' toes. Especially the GPL, since it's very invasive.

@o-nix
Copy link

o-nix commented Mar 22, 2022

Yeah? Is it really a fork or a complete rewrite?

@maxbachmann
Copy link

The project uses a complete copy of GPL licensed code from fuzzywuzzy and python-Levenshtein. See e.g.

private fun getEditOps(len1: Int, s1: String, len2: Int, s2: String): Array<EditOp> {
var len1Copy = len1
var len2Copy = len2
var len1o = 0
val len2o: Int
var i = 0
val matrix: IntArray
val c1 = s1
val c2 = s2
var p1 = 0
var p2 = 0
while (len1Copy > 0 && len2Copy > 0 && c1[p1] == c2[p2]) {
len1Copy--
len2Copy--
p1++
p2++
len1o++
}
len2o = len1o
/* strip common suffix */
while (len1Copy > 0 && len2Copy > 0 && c1[p1 + len1Copy - 1] == c2[p2 + len2Copy - 1]) {
len1Copy--
len2Copy--
}
len1Copy++
len2Copy++
matrix = IntArray(len2Copy * len1Copy)
while (i < len2Copy) {
matrix[i] = i
i++
}
i = 1
while (i < len1Copy) {
matrix[len2Copy * i] = i
i++
}
i = 1
while (i < len1Copy) {
var ptrPrev = (i - 1) * len2Copy
var ptrC = i * len2Copy
val ptrEnd = ptrC + len2Copy - 1
val char1 = c1[p1 + i - 1]
var ptrChar2 = p2
var x = i
ptrC++
while (ptrC <= ptrEnd) {
var c3 = matrix[ptrPrev++] + if (char1 != c2[ptrChar2++]) 1 else 0
x++
if (x > c3) {
x = c3
}
c3 = matrix[ptrPrev] + 1
if (x > c3) {
x = c3
}
matrix[ptrC++] = x
}
i++
}
return editOpsFromCostMatrix(len1Copy, c1, p1, len1o, len2Copy, c2, p2, len2o, matrix)
}

https://github.com/ztane/python-Levenshtein/blob/07785f1516ea099ded127bceea71b5fa41147306/Levenshtein/_levenshtein.c#L5775-L5838

so publishing + using this project under the Apache license is a license violation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants