Automattic / Automattic/jetpack

Simple payments: handle API errors on initialization

Open
#11,899 0 comments 0 reactions 0 assignees View on GitHub
[Block] Pay With Paypal [Feature] Pay with PayPal [Focus] Blocks [Pri] Normal [Status] Needs Design [Type] Question
Dominant language
PHP
Stars
1.8k
Forks
898
Avg merge
1d 18h
Merged PRs (30d)
774

Description

When block loads and attempts to load existing product object with ID it has stored in the block (i.e. the shortcode), several things can go wrong.

- The product doesn't exist anymore. The button has been broken in the frontend, too.
- The API returns something we don't understand or don't think is valid. Give an option to start fresh?
- The API doesn't respond for some reason. If we don't have data to update, what do we do?

How should the UX and visuals look like for these situations?

Gutenberg itself has a notifications helper that looks just a red box with text on it; we can try to find some screenshots to show here.

Contributor guide

Open the contributing guide

Research direction

No files, tests, or entry points are named. Start by locating the Simple Payments block initialization and reviewing Gutenberg's notifications helper. Done means agreeing on UX and visuals for missing products, invalid API data, and unavailable API responses, with implementation scope defined.

Written by the indexing model from the issue text.

Assessment

Tech stack
wordpress
Domain
api, design, frontend, payments
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.