Community library status changes don't update `date_updated`

Đang mở Phù hợp với người mới
#6,414 3 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

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

Từ ngày 16/11/2026.

Đánh giá

Độ khó
2/5
Thời gian dự kiến
1-3 giờ
Mức phù hợp với người mới
84/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
django, python
Lĩnh vực
backend, databases, testing

Hướng nghiên cứu

Đọc CommunityLibrarySubmission.date_updated trong contentcuration/contentcuration/models.py và hai lần cập nhật trạng thái trong contentcuration/contentcuration/viewsets/community_library_submission.py, cùng với phương thức mark_live của model. Thêm các bài kiểm thử hồi quy cho cả hai lần thay đổi trạng thái, theo các bài kiểm thử gần đó. Công việc hoàn tất khi date_updated của mỗi bài gửi được thay đổi khớp với thời điểm trạng thái của nó thay đổi.

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

Mô tả

DEV: backend good first issue help wanted

🙂 Looking for an issue? Welcome! This issue is open for contribution. If this is the first time you’re requesting an issue, please:

  • Read Contributing guidelines carefully. Pay extra attention to Using generative AI. Pull requests and comments that don’t follow the guidelines won’t be answered.
  • Confirm that you’ve read the guidelines in your comment.

Overview

Two community library status changes use QuerySet.update(), which doesn't update auto_now fields, so the affected submissions keep their old date_updated. The notifications filters and the submission list's default ordering both use date_updated, so those status changes are missing from recent notifications and sorted in the wrong place.

Complexity: Low
Target branch: hotfixes

Context
The Change
  • Both status changes should also set date_updated to the time of the change.
Acceptance Criteria
General
  • After a submission is superseded, its date_updated is the time it was superseded.
  • After a live submission is moved back to approved by mark_live, its date_updated is the time of that change.
Testing
  • Both criteria have regression tests.

AI usage

I scoped the audit. Claude Code found these by reading the code and drafted this issue.

Ngôn ngữ chính
Python
Star
212
Fork
321
Merge trung bình
1 ngày 7 giờ
Pull request đã merge (30 ngày)
14

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 learningequality/studio

Tất cả issue của learningequality/studio

Issue tương tự

Thêm issue về Python

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.