Error trying to create a postgres connection
-
Using the full docker image I tried to use my supabase postgres database as storage for my instance.
version: '3.3' services: jsreport: image: jsreport/jsreport:4.4.0-full container_name: jsreport restart: always ports: - "5488:5488" volumes: - <redacted>:/app/data environment: trustUserCode: "true" store_provider: "postgres" extensions_postgres-store_host: "aws-0-eu-central-1.pooler.supabase.com" extensions_postgres-store_port: 5432 extensions_postgres-store_database: "postgres" extensions_postgres-store_user: "postgres.<redacted>" extensions_postgres-store_password: "<redacted>" extensions_postgres-store_ssl: "false"
But when I try to run the container I get the error
[winston] Unknown logger level: { error: TypeError: Cannot use 'in' operator to search for 'key' in false at Socket.<anonymous> (/app/node_modules/pg/lib/connection.js:86:19) at Object.onceWrapper (node:events:632:26) at Socket.emit (node:events:517:28) at Socket.emit (node:domain:489:12) at addChunk (node:internal/streams/readable:368:12) at readableAddChunk (node:internal/streams/readable:341:9) at Readable.push (node:internal/streams/readable:278:10) at TCP.onStreamRead (node:internal/stream_base_commons:190:23), level: 'error', message: "uncaughtException: Cannot use 'in' operator to search for 'key' in false\n" + "TypeError: Cannot use 'in' operator to search for 'key' in false\n" + ' at Socket.<anonymous> (/app/node_modules/pg/lib/connection.js:86:19)\n' + ' at Object.onceWrapper (node:events:632:26)\n' + ' at Socket.emit (node:events:517:28)\n' + ' at Socket.emit (node:domain:489:12)\n' + ' at addChunk (node:internal/streams/readable:368:12)\n' + ' at readableAddChunk (node:internal/streams/readable:341:9)\n' + ' at Readable.push (node:internal/streams/readable:278:10)\n' + ' at TCP.onStreamRead (node:internal/stream_base_commons:190:23)', stack: "TypeError: Cannot use 'in' operator to search for 'key' in false\n" + ' at Socket.<anonymous> (/app/node_modules/pg/lib/connection.js:86:19)\n' + ' at Object.onceWrapper (node:events:632:26)\n' + ' at Socket.emit (node:events:517:28)\n' + ' at Socket.emit (node:domain:489:12)\n' + ' at addChunk (node:internal/streams/readable:368:12)\n' + ' at readableAddChunk (node:internal/streams/readable:341:9)\n' + ' at Readable.push (node:internal/streams/readable:278:10)\n' + ' at TCP.onStreamRead (node:internal/stream_base_commons:190:23)', exception: true, date: 'Sat Jun 15 2024 14:57:21 GMT+0000 (Coordinated Universal Time)', process: [Object], os: [Object], trace: [Array] } (node:1) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 error listeners added to [File]. Use emitter.setMaxListeners() to increase limit (Use `node --trace-warnings ...` to show where the warning was created) (node:1) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 error listeners added to [File]. Use emitter.setMaxListeners() to increase limit (node:1) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 finish listeners added to [File]. Use emitter.setMaxListeners() to increase limit (node:1) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 finish listeners added to [File]. Use emitter.setMaxListeners() to increase limit
I don't really know what to do with this information.
Is my config scuffed or is this a implmentation error.Please let me know if you need more information.
Thanks everyone
-
Try to remove the
ssl: "false"
line.
-
Oh wow it works now.
I tried the option with true and false, I didn't expect that not providing the info was a third option, since we are talking about a bool.Thank you 👍