Open Looxloox opened 4 years ago
We'll fix that ReferenceError but the message it's trying to display is "Invalid or missing translator metadata JSON object", which happens when the metadata at the top of the file can't be parsed as JSON.
Ok, i finally found syntax errors in the URL declaration ("\." instead of "\\.") Thank you for your help
Leaving this open to fix the error message
Following the tutorial proposed by Wikimedia to build new translators, i constructed a "Wikimedia.js" file exactly the way it is described (you can see the file there ). Unfortunately, i can't possibly restart the server after adding this new file to the translators directory (using Docker as well as npm). The error is: `> node src/server.js
(node:23034) UnhandledPromiseRejectionWarning: ReferenceError: filename is not defined at Object.load (/home/abrul/Prog/translation-server/src/translators.js:129:77) at async Object.init (/home/abrul/Prog/translation-server/src/translators.js:48:18) (node:23034) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1) (node:23034) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.` Any idea ?