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

Bug: CollectionCreate form does not display error message when collection creation fails

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

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

@pranjal270 đang làm issue này rồi.

Từ ngày 10/3/2026.

Đánh giá

Issue này chưa được đánh giá.

Mô tả

Bug
p5.js version

No response

What is your operating system?

Windows

Web browser and version

chrome://145.0.7632.117

Actual Behavior

In the collection creation form, the error handling logic for creating a new sketch collection is incomplete. The local state creationError is defined but never updated when the createCollection action fails.

When collection creation fails (e.g., due to a network error or backend validation failure), no error message is shown to the user because creationError remains undefined. The createCollection action dispatches an ERROR action on failure, but the component neither listens to this state nor catches the error.

Expected Behavior

The component should display an appropriate error message when collection creation fails.

This can be achieved either by:

  • reading the error state from Redux, or

  • modifying the action to return a rejected Promise so the component can catch it and set its local creationError state to true.

Steps to reproduce

###Steps:

  1. Navigate to the Collection Creation page.
  2. Intercept the network request to the /collections endpoint and force it to fail (for example, return a 500 error).
  3. Attempt to create a collection.
  4. Observe that no error message is displayed despite the failure.
Snippet:
// TODO: error is never set!
// eslint-disable-next-line no-unused-vars
const [creationError, setCreationError] = useState();
Ngôn ngữ chính
JavaScript
Star
1.7k
Fork
1.7k
Merge trung bình
6 ngày
Pull request đã merge (30 ngày)
10

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

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 processing/p5.js-web-editor

Tất cả issue của processing/p5.js-web-editor

Issue tương tự

Thêm issue về JavaScript

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.