Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CAL-3974] Multiple Slots.getSchedule requests being sent when typing email on booker page #15574

Open
Amit91848 opened this issue Jun 26, 2024 · 2 comments 路 May be fixed by #15616
Open

[CAL-3974] Multiple Slots.getSchedule requests being sent when typing email on booker page #15574

Amit91848 opened this issue Jun 26, 2024 · 2 comments 路 May be fixed by #15616
Labels
booking-page area: booking page, public booking page, booker 馃悰 bug Something isn't working Medium priority Created by Linear-GitHub Sync performance area: performance, page load, slow, slow endpoints, loading screen, unresponsive
Milestone

Comments

@Amit91848
Copy link
Contributor

Amit91848 commented Jun 26, 2024

Found a bug? Please fill out the sections below. 馃憤

Issue Summary

When booking an event-type, entering email makes multiple requests for getSchedule. Tried with other question formats too but ig this is only broken for required email.

Steps to Reproduce

  1. Create event-type
  2. Try making a booking for that event
  3. Open up chrome dev tools and check network tab
Recording.2024-06-26.133431.mp4

Actual Results

  • Multiple unrelated requests are being sent

Expected Results

  • No requests should be sent

CAL-3974

@dosubot dosubot bot added booking-page area: booking page, public booking page, booker 馃悰 bug Something isn't working labels Jun 26, 2024
Copy link

dosubot bot commented Jun 26, 2024

Entering an email address in a required email field triggers multiple getSchedule requests due to the email field validation process, which involves several steps and checks. Each modification to the email field prompts the system to validate the input against various schemas, leading to multiple getSchedule requests. This is part of the preprocess function within the getBookingResponsesSchema function [1].

For more details, you can refer to a similar closed issue: getSchedule called twice on booking page, which was resolved by removing the double call on useSchedule() [2].

To continue talking to Dosu, mention @dosu.

@PeerRich PeerRich added performance area: performance, page load, slow, slow endpoints, loading screen, unresponsive Medium priority Created by Linear-GitHub Sync labels Jun 26, 2024
@PeerRich PeerRich added this to the v4.4 milestone Jun 26, 2024
@PeerRich PeerRich changed the title Multiple Slots.getSchedule requests being sent when typing email on booker page [CAL-3974] Multiple Slots.getSchedule requests being sent when typing email on booker page Jun 26, 2024
@nishchal27
Copy link

These two Requests are called on every keystroke in the "Email address" field:

https://cal.com/api/trpc/public/slots.getSchedule
https://cal.com/api/trpc/public/checkIfUserEmailVerificationRequired

this happens when typing in "Email address" field only

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
booking-page area: booking page, public booking page, booker 馃悰 bug Something isn't working Medium priority Created by Linear-GitHub Sync performance area: performance, page load, slow, slow endpoints, loading screen, unresponsive
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants