Refactor or deprecate parent-child relationships between XBlocks
@kdmccormick đang làm issue này rồi.
Từ ngày 10/11/2025.
Đánh giá
Issue này chưa được đánh giá.
Mô tả
This would be a long-term initiative. It probably belongs on the platform-roadmap.
Context
We have decided that parent-child relationships should only exist at/below the VerticalBlock: https://github.com/openedx/edx-platform/blob/master/docs/decisions/0006-role-of-xblock.rst
We have further discussed that parent-child relationships in their entirety should be removed; I'm not sure if we came to a consensus on that.
TODO -- Add more context ( @ormsbee , @kdmccormick , and @bradenmacdonald ).
Tasks
Off the top of my head...
- File a DEPR encompassing our plan to:
- Remove parent-child relationships on the base XBlock class. Delete the _HasChildrenMetaclass. Move all parent-child logic to a new subclass, XBlockWithChildren. Make it
XBlock.has_childrena read-only class property. Some details. - Raise an exception if
get_parentis called at or above the VerticalBlock level. - For all XBlockWithChildren subclasses above the VerticalBlock (so, CourseBlock, SectionBlock, and SequenceBlock): Move their implementations to either Learning Core or edx-platform djangoapps.
- Remove parent-child relationships on the base XBlock class. Delete the _HasChildrenMetaclass. Move all parent-child logic to a new subclass, XBlockWithChildren. Make it
- Decide: Should parent-child relationships still exist at/below the Vertical block?
- Either way -> ADR it.
- Yes -> We're done.
- No -> File another DEPR encompassing our plan to:
- Raise deprecation warnings on the XBlockWithChildren class.
- For all remaining XBlockWithChildren subclasses in edx-platform (eg, LibraryContentBlock, SplitTestBlock):
Move their implementations to either Learning Core or edx-platform djangoapps. - Write guidance on how custom XBlockWithChildren subclasses can be similarly migrated. Ensure that, for example, OpenCraft's ProblemBuilder block can be migrated using this guide.
- Delete the XBlockWithChildren class, and delete all parent-child logic from the XBlock repository.
- Delete all parent-child logic from modulestore and edx-platform's XBlock runtimes.
- Ngôn ngữ chính
- Python
- Star
- 470
- Fork
- 231
- Merge trung bình
- 2 ngày 14 giờ
- Pull request đã merge (30 ngày)
- 7
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- 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.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của openedx/XBlock
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 72/100
-
performance
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 35/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 45/100
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
-
[DEPR]: Support for XBlock Runtimes with raw string scope IDsCó thể đã có người làm @salman2013 đã nhận 211 ngày trước. Đang mởdepr
openedx/XBlock#784 · 10 bình luận · 3 reaction · 1 người được giao ·
Tất cả issue của openedx/XBlock
Issue tương tự
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
Deepak3699/Ai_Mentor#244 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
btclib-org/btclib-node#1880 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
CONTRIBUTING.md: say how ticketless bug fixes and feature PRs are handledCó thể đã có người làm @khuisman đã nhận hôm nay. Đang mởv0.9.2
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 84/100
khuisman/mcp-gee-sweet#941 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
pyjanitor-devs/pyjanitor#1758 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug ready for review
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
odysseus-dev/odysseus#6641 ·
Maintainer thường phản hồi trong vòng 1 ngày