Resolve "Certaines erreurs ne sont pas catchées dans les plugins de groupes"
Closes #855 (closed)
Il est possible de tester ce correctif sur eole3.dev en se connectant avec l'utilisateur user_000003
Avant correction, une exception doit apparaître dans les logs :
(node:1) UnhandledPromiseRejectionWarning: FetchError: request to https://yocloud.fr/ocs/v1.php/cloud/users?search=user_000003 failed, reason: read ECONNRESET
at ClientRequest.<anonymous> (packages/modules.js:5794:11)
at ClientRequest.emit (events.js:400:28)
at ClientRequest.emit (domain.js:475:12)
at TLSSocket.socketErrorListener (_http_client.js:478:9)
at TLSSocket.emit (events.js:400:28)
at TLSSocket.emit (domain.js:475:12)
at emitErrorNT (internal/streams/destroy.js:106:8)
at emitErrorCloseNT (internal/streams/destroy.js:74:3)
at processTicksAndRejections (internal/process/task_queues.js:82:21)
=> awaited here:
at Function.Promise.await (/opt/bundle/bundle/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/promise_server.js:56:12)
at imports/api/appclients/nextcloud.js:74:19
at /opt/bundle/bundle/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/fiber_pool.js:43:40
=> awaited here:
at Function.Promise.await (/opt/bundle/bundle/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/promise_server.js:56:12)
at imports/api/appclients/nextcloud.js:578:20
at /opt/bundle/bundle/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/fiber_pool.js:43:40
(Use `node --trace-warnings ...` to show where the warning was created)
(node:1) 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(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:1) [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.
Après correction, un log d'erreur devrait apparaître (en rouge)
Edited by Bruno Boiget