saleor/saleor

Provide better message for transactionAPI

Open

#13,951 创建于 2023年9月11日

在 GitHub 查看
 (4 评论) (0 反应) (0 负责人)Python (19,887 star) (5,278 fork)batch import
good first issuetransactionAPI

描述

Problem

We can improve the message that we provide from transactionEventReport, and transaction API. This can give more context when analyzing the de-duplicated events. Add context (if possible) like:

  • amount
  • pspReference
  • event type returned by app

For example, transactionEventReport creates the event with message:

The transaction with provided `pspReference` and `type` already exists with different amount.

It doesn't contain enough details to determine the what type of the event we received, or what was the psp-reference which raised the error.


The mutation that should be checked transactionEventReport, transactionInitialize, transactionProcess, transactionCreate, transactionUpdate, transactionRequestAction. To any event created by Saleor implementation, we should provide more context. For example: instead of msg like: "Provided event type is invalid", we should have: f"Provided event type: {response.type} is invalid."

Acceptance Criteria

  • The events created by Saleor for transactionAPI includes the details (type, pspReference) required to analyze the flow

贡献者指南

Provide better message for transactionAPI · saleor/saleor#13951 | Good First Issue