We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d49cc0a commit afca20fCopy full SHA for afca20f
apertium/utils.py
@@ -74,13 +74,12 @@ def execute_pipeline(inp: str, commands: List[List[str]]) -> str:
74
input_file.close()
75
76
if 'lt-proc' == command[0]:
77
- dictionary_path = command[-1]
+ lt_proc_command, dictionary_path = command[:-1], command[-1]
78
lttoolbox.LtLocale.tryToSetLocale()
79
fst = lttoolbox.FST(dictionary_path)
80
if not fst.valid():
81
raise ValueError('FST Invalid')
82
- lt_proc_command = command[:-1]
83
- fst.lt_proc(len(lt_proc_command), lt_proc_command, input_file.name, output_file.name)
+ fst.lt_proc(lt_proc_command, input_file.name, output_file.name)
84
elif 'lrx-proc' == command[0]:
85
dictionary_path = command[-1]
86
lextools.LtLocale.tryToSetLocale()
0 commit comments