Rank 3: Container
I'm facing a "simple" issue
Invalid response. This usually means too large logs or errors. Please avoid logging files or lengthy strings.\nError Code: 500I think i've found where it's happen due to a JSON.stringify() i try to log.
My code is organise like this
function myFunction({log, error}) { log('Start my function'); try { // Do some stuff log(`I get this var: ${myVar}`); // Do some other stuff that throws an exception throw "myException"; // Generate an exception } catch (e) { error('An error occurred'); error(`Error message: ${JSON.stringify(e)}`); // <-- This throw the error due to too long message }}The issue, is that log before throw exception are not log. So it's very difficult to debug.