Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

The safety policy hands off a Shopify order note as "moving money" while refunds pass

Đang mở
#890 2 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
48/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
typescript

Hướng nghiên cứu

Start with the payments rule in server/src/approvals/policy.ts and trace how the safety policy evaluates Shopify action names, descriptions, and arguments. Check how SHOPIFY_UPDATE_ORDER and SHOPIFY_CREATE_REFUND are represented and covered by existing tests. Done means notes on an order no longer trigger a money hand-off while refunds do; the proposed administrator allow rule is an additional design question.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

bug

What happens

Writing a note on a Shopify order (SHOPIFY_UPDATE_ORDER with only id and note) is handed off to the person as a money action:

approval.evaluated  composio-shopify/SHOPIFY_UPDATE_ORDER
  outcome: { behaviour: "hand_off", source: "safety",
             reason: "Paying, purchasing or moving money is always done by the person." }

Meanwhile SHOPIFY_CREATE_REFUND, which does move money, passes without a hand-off.

The payments rule in server/src/approvals/policy.ts is a keyword regex (payment|pay|checkout|purchase|place order|... |billing). The order-update action's schema or description very likely matched on a word such as billing (it has a billing_address field), while "refund" is not in the list at all.

Suggested fix

  • Classify on what the action does, not on words found anywhere in its schema. At least match against the action's name and the arguments actually sent, not field names that were left empty.
  • Add refunds to the money rule (refund, create_refund), since they move money.
  • Consider letting an administrator mark a specific action as not money-moving (an allow rule that the safety layer respects), with the decision recorded in the audit log.
Ngôn ngữ chính
TypeScript
Star
7.1k
Fork
962
Merge trung bình
1 ngày 6 giờ
Pull request đã merge (30 ngày)
143

Chuẩn bị môi trường

  • Có Dockerfile hoặc tệp Docker Compose
  • Có mẫu pull request
  • Không có hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của CopilotKit/OpenBot

Tất cả issue của CopilotKit/OpenBot

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.