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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Streamline network calls for resetting level progress 🛠🛠 #645

Closed
heatherlogan-scottlogic opened this issue Dec 11, 2023 · 0 comments · Fixed by #872
Closed

Streamline network calls for resetting level progress 🛠🛠 #645

heatherlogan-scottlogic opened this issue Dec 11, 2023 · 0 comments · Fixed by #872
Assignees
Labels
backend Requires work on the backend frontend Requires work on the frontend refactor Improve code quality

Comments

@heatherlogan-scottlogic
Copy link
Contributor

heatherlogan-scottlogic commented Dec 11, 2023

Here's what happens when you reset level progress:

  • openai/clear clears the chat history for given level.
  • email/clear clears the emails for given level.
  • openai/addHistory adds the "Level progress reset" info message to given level's chat history

These should be one request.

AC:

regression check tat resetting level progress works as expected

GIVEN frontend in preview mode (so that react doesn't do its double render thing) npm run preview
WHEN the user changes from one level to another (check specifically switching in and out of sandbox)
THEN there should be only one api call made of type fetch

Here's how you quickly find out what api calls are being made that are fetch type. Note that the CombinedFonts call is of type xhr, therefore we ignore it.

image

@heatherlogan-scottlogic heatherlogan-scottlogic added frontend Requires work on the frontend backend Requires work on the backend refactor Improve code quality labels Dec 11, 2023
@pmarsh-scottlogic pmarsh-scottlogic changed the title Combine level reset requests into one Streamline network calls for resetting level progress 🛠🛠 Feb 6, 2024
@pmarsh-scottlogic pmarsh-scottlogic self-assigned this Mar 21, 2024
@pmarsh-scottlogic pmarsh-scottlogic linked a pull request Mar 21, 2024 that will close this issue
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Requires work on the backend frontend Requires work on the frontend refactor Improve code quality
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants