Node.js/err

来自康健生活
Kangkk​(留言 | 贡献)2020年7月22日 (三) 12:35的版本 (→引言)

引言

  • UnhandledPromiseRejectionWarning: TypeError: Converting circular structure to JSON
    定位问题
    process.on('unhandledRejection', (reason, p) => {
                console.log('Unhandled Rejection at: Promise', p, 'reason:', reason);
                // application specific logging, throwing an error, or other logic here
            });
    
  • property 'socket' -> object with constructor 'Socket'
  • Cannot set headers after they are sent to the client
  • verbose stack spawn ENOENT