Open frank-bee opened 10 months ago
Hi @frank-bee can you share your table schema, i can take look
oh nice! this is the table https://rowy.app/p/bedstories-8ebd2/table/stories
the column I changed was "Stories". but I think I reverted the changes and still get the error. maybe one of my imported packages changed. I use chatgpt API and a text2speach api from 11labs ( in some other column)
thanks for helping me @shamsmosowi
@shamsmosowi it seems to be in the azure lib in the derivative in the url column:
stderr: /home/node/app/build/functionBuilder/builds/1699084535870/node_modules/microsoft-cognitiveservices-speech-sdk/distrib/lib/microsoft.cognitiveservices.speech.sdk.js:3
import { ConsoleLoggingListener } from "./src/common.browser/Exports";
^^^^^^
SyntaxError: Cannot use import statement outside a module
at internalCompileFunction (node:internal/vm:73:18)
at wrapSafe (node:internal/modules/cjs/loader:1178:20)
at Module._compile (node:internal/modules/cjs/loader:1220:27)
at Module._extensions..js (node:internal/modules/cjs/loader:1310:10)
at Module.load (node:internal/modules/cjs/loader:1119:32)
at Module._load (node:internal/modules/cjs/loader:960:12)
at Module.require (node:internal/modules/cjs/loader:1143:19)
at require (node:internal/modules/cjs/helpers:110:18)
at Object.<anonymous> (/home/node/app/build/functionBuilder/builds/1699084535870/src/derivatives/url.js:100:13)
at Module._compile (node:internal/modules/cjs/loader:1256:14)
error Command failed with exit code 1.
I moved the import statement ( not the one in the error message but the one were I import the surrounding package) inside a function, no it works
I tested it again: issue is still there, now during runtime, not deplyoment.
@shamsmosowi this issue and #1471 both had todo with this azure package 'microsoft-cognitiveservices-speech-sdk'.
When importing this ( with require
) , this messes up my complete rowy function ( of even the other functions of other tables?).
below some sample code how you could test this.
What I do to temp. fix this, I fixed the package.json
, downgrading to "microsoft-cognitiveservices-speech-sdk": "1.32.0",
How can I do this with rowy?
sample code for reproducing this issue
function synthesizeSpeech(logging) {
var sdk = require("microsoft-cognitiveservices-speech-sdk");
const speechConfig = sdk.SpeechConfig.fromSubscription("..", "eastus");
const speechSynthesizer = new sdk.SpeechSynthesizer(speechConfig);
speechSynthesizer.speakTextAsync(
"I'm excited to try text to speech",
result => {
logging.log("ok");
speechSynthesizer.close();
return result.audioData;
},
error => {
logging.log(error);
speechSynthesizer.close();
});
}
Describe the bug When deploying a function (derivative) , I get this error during deploy: (Did not change a lot , no import statements, in my code)
Rowy Run version latest (I work with the browser)