rcmaples / shftr

0 stars 0 forks source link

Error when deleting appointments with "This and following appointments" option. #6

Closed rcmaples closed 2 years ago

rcmaples commented 2 years ago

Google's API is throwing an error when modifying an event with "This and following..." option in shftr. This is causing some odd behavior. Need to investigate to see what's causing this.

2021-10-04T12:56:46.119334+00:00 heroku[router]: at=error code=H12 desc="Request timeout" method=PATCH path="/api/appointments/614252937b9b980004b9d461" host=shftr.fyi request_id=381f7610-0cad-4ae4-a6fa-3f6dc8f399e8 fwd="71.204.51.67" dyno=web.1 connect=0ms service=30000ms status=503 bytes=0 protocol=https
2021-10-04T12:56:46.120694+00:00 app[web.1]: PATCH /api/appointments/614252937b9b980004b9d461 - 242.600 ms - -
2021-10-04T12:56:55.619527+00:00 app[web.1]: Successfully created the event: 7rivieoveq6jmklt2k1d53b978
2021-10-04T12:56:55.661057+00:00 app[web.1]: POST /api/appointments 200 812.202 ms - 371
2021-10-04T12:56:55.661888+00:00 heroku[router]: at=info method=POST path="/api/appointments" host=shftr.fyi request_id=7efb719f-f467-4777-b7bc-8e528cc9d207 fwd="71.204.51.67" dyno=web.1 connect=0ms service=814ms status=200 bytes=682 protocol=https
2021-10-04T12:57:05.378408+00:00 app[web.1]: recurrence:
2021-10-04T12:57:05.378415+00:00 app[web.1]: [
2021-10-04T12:57:05.378416+00:00 app[web.1]: 'EXDATE;VALUE=DATE:20210921T180000Z',
2021-10-04T12:57:05.378418+00:00 app[web.1]: 'INTERVAL=1;FREQ=WEEKLY;UNTIL=20210928T180000Z'
2021-10-04T12:57:05.378419+00:00 app[web.1]: ]
2021-10-04T12:57:05.379178+00:00 app[web.1]: updatedEvent Promise { <pending> }
2021-10-04T12:57:05.548872+00:00 app[web.1]: There was an error creating the event on Google Calender: Error: Invalid recurrence rule.
2021-10-04T12:57:05.549509+00:00 app[web.1]: GaxiosError: Invalid recurrence rule.
2021-10-04T12:57:05.549511+00:00 app[web.1]: at Gaxios._request (/app/node_modules/gaxios/build/src/gaxios.js:129:23)
2021-10-04T12:57:05.549512+00:00 app[web.1]: at runMicrotasks (<anonymous>)
2021-10-04T12:57:05.549512+00:00 app[web.1]: at processTicksAndRejections (internal/process/task_queues.js:95:5)
2021-10-04T12:57:05.549519+00:00 app[web.1]: at async JWT.requestAsync (/app/node_modules/google-auth-library/build/src/auth/oauth2client.js:368:18) {
2021-10-04T12:57:05.549519+00:00 app[web.1]: response: {
2021-10-04T12:57:05.549520+00:00 app[web.1]: config: {
2021-10-04T12:57:05.549521+00:00 app[web.1]: url: 'https://www.googleapis.com/calendar/v3/calendars/c_scvkfhjpjj8bghufa29e0r0mkg%40group.calendar.google.com/events/3cs97c2pcbc7709h4v29isrp6o',
2021-10-04T12:57:05.549521+00:00 app[web.1]: method: 'PUT',
2021-10-04T12:57:05.549521+00:00 app[web.1]: userAgentDirectives: [Array],
2021-10-04T12:57:05.549522+00:00 app[web.1]: paramsSerializer: [Function (anonymous)],
2021-10-04T12:57:05.549522+00:00 app[web.1]: data: [Object],
2021-10-04T12:57:05.549522+00:00 app[web.1]: headers: [Object],
2021-10-04T12:57:05.549523+00:00 app[web.1]: params: {},
2021-10-04T12:57:05.549523+00:00 app[web.1]: validateStatus: [Function (anonymous)],
2021-10-04T12:57:05.549523+00:00 app[web.1]: retry: true,
2021-10-04T12:57:05.549524+00:00 app[web.1]: body: '{"sendUpdates":"All","start":{"dateTime":"2021-09-21T18:00:00.000Z","timeZone":"Etc/UTC"},"end":{"dateTime":"2021-09-21T20:00:00.000Z","timeZone":"Etc/UTC"},"attendees":[{"email":"rc@fullstory.com"}],"summary":"RC Queue Shift","recurrence":["EXDATE;VALUE=DATE:20210921T180000Z","INTERVAL=1;FREQ=WEEKLY;UNTIL=20210928T180000Z"]}',
2021-10-04T12:57:05.549525+00:00 app[web.1]: responseType: 'json',
2021-10-04T12:57:05.549525+00:00 app[web.1]: retryConfig: [Object]
2021-10-04T12:57:05.549525+00:00 app[web.1]: },
2021-10-04T12:57:05.549526+00:00 app[web.1]: data: { error: [Object] },
2021-10-04T12:57:05.549526+00:00 app[web.1]: headers: {
2021-10-04T12:57:05.549527+00:00 app[web.1]: 'alt-svc': 'h3=":443"; ma=2592000,h3-29=":443"; ma=2592000,h3-T051=":443"; ma=2592000,h3-Q050=":443"; ma=2592000,h3-Q046=":443"; ma=2592000,h3-Q043=":443"; ma=2592000,quic=":443"; ma=2592000; v="46,43"',
2021-10-04T12:57:05.549527+00:00 app[web.1]: 'cache-control': 'no-cache, no-store, max-age=0, must-revalidate',
2021-10-04T12:57:05.549527+00:00 app[web.1]: connection: 'close',
2021-10-04T12:57:05.549527+00:00 app[web.1]: 'content-encoding': 'gzip',
2021-10-04T12:57:05.549528+00:00 app[web.1]: 'content-type': 'application/json; charset=UTF-8',
2021-10-04T12:57:05.549528+00:00 app[web.1]: date: 'Mon, 04 Oct 2021 12:57:05 GMT',
2021-10-04T12:57:05.549528+00:00 app[web.1]: expires: 'Mon, 01 Jan 1990 00:00:00 GMT',
2021-10-04T12:57:05.549529+00:00 app[web.1]: pragma: 'no-cache',
2021-10-04T12:57:05.549529+00:00 app[web.1]: server: 'ESF',
2021-10-04T12:57:05.549529+00:00 app[web.1]: 'transfer-encoding': 'chunked',
2021-10-04T12:57:05.549529+00:00 app[web.1]: vary: 'Origin, X-Origin, Referer',
2021-10-04T12:57:05.549530+00:00 app[web.1]: 'x-content-type-options': 'nosniff',
2021-10-04T12:57:05.549530+00:00 app[web.1]: 'x-frame-options': 'SAMEORIGIN',
2021-10-04T12:57:05.549530+00:00 app[web.1]: 'x-xss-protection': '0'
2021-10-04T12:57:05.549530+00:00 app[web.1]: },
2021-10-04T12:57:05.549530+00:00 app[web.1]: status: 400,
2021-10-04T12:57:05.549531+00:00 app[web.1]: statusText: 'Bad Request',
2021-10-04T12:57:05.549531+00:00 app[web.1]: request: {
2021-10-04T12:57:05.549532+00:00 app[web.1]: responseURL: 'https://www.googleapis.com/calendar/v3/calendars/c_scvkfhjpjj8bghufa29e0r0mkg%40group.calendar.google.com/events/3cs97c2pcbc7709h4v29isrp6o'
2021-10-04T12:57:05.549532+00:00 app[web.1]: }
2021-10-04T12:57:05.549532+00:00 app[web.1]: },
2021-10-04T12:57:05.549532+00:00 app[web.1]: config: {
2021-10-04T12:57:05.549533+00:00 app[web.1]: url: 'https://www.googleapis.com/calendar/v3/calendars/c_scvkfhjpjj8bghufa29e0r0mkg%40group.calendar.google.com/events/3cs97c2pcbc7709h4v29isrp6o',
2021-10-04T12:57:05.549533+00:00 app[web.1]: method: 'PUT',
2021-10-04T12:57:05.549533+00:00 app[web.1]: userAgentDirectives: [ [Object] ],
2021-10-04T12:57:05.549533+00:00 app[web.1]: paramsSerializer: [Function (anonymous)],
2021-10-04T12:57:05.549533+00:00 app[web.1]: data: {
2021-10-04T12:57:05.549534+00:00 app[web.1]: sendUpdates: 'All',
2021-10-04T12:57:05.549534+00:00 app[web.1]: start: [Object],
2021-10-04T12:57:05.549534+00:00 app[web.1]: end: [Object],
2021-10-04T12:57:05.549534+00:00 app[web.1]: attendees: [Array],
2021-10-04T12:57:05.549534+00:00 app[web.1]: summary: 'RC Queue Shift',
2021-10-04T12:57:05.549535+00:00 app[web.1]: recurrence: [Array]
2021-10-04T12:57:05.549535+00:00 app[web.1]: },
2021-10-04T12:57:05.549535+00:00 app[web.1]: headers: {
2021-10-04T12:57:05.549535+00:00 app[web.1]: 'x-goog-api-client': 'gdcl/5.0.5 gl-node/14.17.0 auth/7.9.1',
2021-10-04T12:57:05.549535+00:00 app[web.1]: 'Accept-Encoding': 'gzip',
2021-10-04T12:57:05.549536+00:00 app[web.1]: 'User-Agent': 'google-api-nodejs-client/5.0.5 (gzip)',
2021-10-04T12:57:05.549537+00:00 app[web.1]: Authorization: 'Bearer ya29.a0ARrdaM-IH92eG5wwxglttnz_A_iEWU9PEq9xjAJ5QqFGBnDgBKorEwcq2830oRkPwwb9Xjtnlg2HVGykrKD_Ub_dz9itj3kKSUZKgeSLQM86XD4r8-5ZcGgHOhzmegfwf3ipvOZtchhzWArcSwuyqnoFaIf6V9CGAY-Jw-dGnylV660fRygx5wu5pyCM68ELkawj9opDAvk',
2021-10-04T12:57:05.549537+00:00 app[web.1]: 'Content-Type': 'application/json',
2021-10-04T12:57:05.549537+00:00 app[web.1]: Accept: 'application/json'
2021-10-04T12:57:05.549537+00:00 app[web.1]: },
2021-10-04T12:57:05.549537+00:00 app[web.1]: params: {},
2021-10-04T12:57:05.549538+00:00 app[web.1]: validateStatus: [Function (anonymous)],
2021-10-04T12:57:05.549538+00:00 app[web.1]: retry: true,
2021-10-04T12:57:05.549538+00:00 app[web.1]: body: '{"sendUpdates":"All","start":{"dateTime":"2021-09-21T18:00:00.000Z","timeZone":"Etc/UTC"},"end":{"dateTime":"2021-09-21T20:00:00.000Z","timeZone":"Etc/UTC"},"attendees":[{"email":"rc@fullstory.com"}],"summary":"RC Queue Shift","recurrence":["EXDATE;VALUE=DATE:20210921T180000Z","INTERVAL=1;FREQ=WEEKLY;UNTIL=20210928T180000Z"]}',
2021-10-04T12:57:05.549539+00:00 app[web.1]: responseType: 'json',
2021-10-04T12:57:05.549539+00:00 app[web.1]: retryConfig: {
2021-10-04T12:57:05.549539+00:00 app[web.1]: currentRetryAttempt: 0,
2021-10-04T12:57:05.549539+00:00 app[web.1]: retry: 3,
2021-10-04T12:57:05.549539+00:00 app[web.1]: httpMethodsToRetry: [Array],
2021-10-04T12:57:05.549540+00:00 app[web.1]: noResponseRetries: 2,
2021-10-04T12:57:05.549540+00:00 app[web.1]: statusCodesToRetry: [Array]
2021-10-04T12:57:05.549540+00:00 app[web.1]: }
2021-10-04T12:57:05.549540+00:00 app[web.1]: },
2021-10-04T12:57:05.549540+00:00 app[web.1]: code: 400,
2021-10-04T12:57:05.549541+00:00 app[web.1]: errors: [
2021-10-04T12:57:05.549541+00:00 app[web.1]: {
2021-10-04T12:57:05.549541+00:00 app[web.1]: domain: 'global',
2021-10-04T12:57:05.549541+00:00 app[web.1]: reason: 'invalid',
2021-10-04T12:57:05.549542+00:00 app[web.1]: message: 'Invalid recurrence rule.'
2021-10-04T12:57:05.549542+00:00 app[web.1]: }
2021-10-04T12:57:05.549542+00:00 app[web.1]: ]
2021-10-04T12:57:05.549542+00:00 app[web.1]: }
2021-10-04T12:57:05.550012+00:00 app[web.1]: (node:4) UnhandledPromiseRejectionWarning: RangeError [ERR_HTTP_INVALID_STATUS_CODE]: Invalid status code: undefined
2021-10-04T12:57:05.550013+00:00 app[web.1]: at ServerResponse.writeHead (_http_server.js:259:11)
2021-10-04T12:57:05.550014+00:00 app[web.1]: at ServerResponse.writeHead (/app/node_modules/on-headers/index.js:44:26)
2021-10-04T12:57:05.550014+00:00 app[web.1]: at ServerResponse._implicitHeader (_http_server.js:250:8)
2021-10-04T12:57:05.550014+00:00 app[web.1]: at write_ (_http_outgoing.js:711:9)
2021-10-04T12:57:05.550015+00:00 app[web.1]: at ServerResponse.end (_http_outgoing.js:825:5)
2021-10-04T12:57:05.550015+00:00 app[web.1]: at ServerResponse.send (/app/node_modules/express/lib/response.js:221:10)
2021-10-04T12:57:05.550015+00:00 app[web.1]: at ServerResponse.json (/app/node_modules/express/lib/response.js:267:15)
2021-10-04T12:57:05.550016+00:00 app[web.1]: at /app/routes/api/appointments.route.js:119:28
2021-10-04T12:57:05.550016+00:00 app[web.1]: at runMicrotasks (<anonymous>)
2021-10-04T12:57:05.550016+00:00 app[web.1]: at processTicksAndRejections (internal/process/task_queues.js:95:5)
2021-10-04T12:57:05.551592+00:00 app[web.1]: (node:4) 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: 2)