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
For the sample below :
%22+
Math
.ran
dom(
)+%2
233e
call: python /usr/local/bin/inferrer/cli.py /tmp/params/rnd /tmp/no rpni
Gives the result of:
(t|r|o|n|m|h|e|d|a|M|3|2|.|+|)|(|%)*
While for the sample below, only extends the last item:
%22+
Math
.ran
dom(
)+%2
233eab
call: python /usr/local/bin/inferrer/cli.py /tmp/params/rnd /tmp/no rpni
---->go into endless processing
From top, the process of "python" takes 100% cpu.
The text was updated successfully, but these errors were encountered:
It can be fixed like this:
def _generate_set(s: Set[str], alphabet: Set[str], func: Callable) -> Generator:
for si in s :
slen = len( si )
for k in range(1,slen+1) :
substr = si[0:k]
yield substr
#if alphabet is None:
# alphabet = determine_alphabet(s)
#longest = len(max(s, key=len))
#for comb in _get_all_combinations(alphabet, longest):
# if any([func(i, comb) for i in s]):
# yield comb
Hi, thanks for letting me know. This issue has been fixed in the latest commit - your solution made the existing test cases fail, since it caused the prefix and suffix sets to generate incorrectly.
For the sample below :
%22+
Math
.ran
dom(
)+%2
233e
call: python /usr/local/bin/inferrer/cli.py /tmp/params/rnd /tmp/no rpni
Gives the result of:
(t|r|o|n|m|h|e|d|a|M|3|2|.|+|)|(|%)*
While for the sample below, only extends the last item:
%22+
Math
.ran
dom(
)+%2
233eab
call: python /usr/local/bin/inferrer/cli.py /tmp/params/rnd /tmp/no rpni
---->go into endless processing
From top, the process of "python" takes 100% cpu.
The text was updated successfully, but these errors were encountered: