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

Add retry button for error page #85

Merged
merged 5 commits into from
Sep 15, 2023
Merged

Conversation

Raidakarim
Copy link
Contributor

@Raidakarim Raidakarim commented Sep 10, 2023

Describe this pull request. Link to relevant GitHub issues, if any.

This PR includes issue #84 deliverables as detailed in the following:
Added a retry boolean variable in the RobotMotion.jsx file. This retry boolean is true only when “Robot has encountered an error” text appears. When retry boolean is true a Retry button appears in the error page. I placed this button in the latter 50% of the page's viewbox and made it vertically and horizontally centered in that part. I used yellow for this button’s color as this is meant for an unintended / erroneous situation. When this button is clicked, the current robot motion starts again from planning, just like what the footer's resume button does when the robot is paused.

UPDATES:

  • Assigned default value to retry in the function definition
  • Changed resumeCallback function onclick
  • Placed 'Retry' button in the prior 50% of the page's viewbox

Explain how this pull request was tested, including but not limited to the below checkmarks.

This feature was tested in Ubuntu VM 22.04 chromium and firefox browser in landscape and portrait modes of smartphone, tablet, desktop monitor, and laptop. The retry button appeared as expected and re-started the current action when the retry button is clicked.


Before creating a pull request

  • Format React code with npm run format
  • [N/A] Format Python code by running python3 -m black . in the top-level of this repository
  • [N/A] Thoroughly test your code's functionality, including unintended uses.
  • Fully test the responsiveness of the feature as documented in the Responsiveness Testing Guidelines. If you deviate from those guidelines, document above why you deviated and what you did instead.
  • Consider the user flow between states that this feature introduces, consider different situations that might occur for the user, and ensure that there is no way for the user to get stuck in a loop.

Before merging a pull request

  • Squash all your commits into one (or Squash and Merge)

@Raidakarim Raidakarim self-assigned this Sep 10, 2023
@Raidakarim Raidakarim linked an issue Sep 10, 2023 that may be closed by this pull request
Copy link
Contributor

@amalnanavati amalnanavati left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall, this looks good. Thank you for addressing this promptly!

I have a few in-line requests for changes, but once those are addressed this should be good to go.

feedingwebapp/src/Pages/Home/MealStates/RobotMotion.jsx Outdated Show resolved Hide resolved
feedingwebapp/src/Pages/Home/MealStates/RobotMotion.jsx Outdated Show resolved Hide resolved
feedingwebapp/src/Pages/Home/MealStates/RobotMotion.jsx Outdated Show resolved Hide resolved
Copy link
Contributor

@amalnanavati amalnanavati left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See requested changes. I did test it on my phone with the real robot and it works well.

feedingwebapp/src/Pages/Home/MealStates/RobotMotion.jsx Outdated Show resolved Hide resolved
feedingwebapp/src/Pages/Home/MealStates/RobotMotion.jsx Outdated Show resolved Hide resolved
@Raidakarim Raidakarim merged commit 7d5e40e into main Sep 15, 2023
4 checks passed
@Raidakarim Raidakarim deleted the raidak/error_retry_button branch September 15, 2023 19:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add a Retry Button When the Robot Encounters an Error
2 participants