Registry / web-framework / xblock-drag-and-drop-v2

xblock-drag-and-drop-v2

JSON →
library5.0.6pypypi✓ verified 85d ago

An XBlock for Open edX that provides a drag-and-drop problem type. Current version is 5.0.6, requires Python >=3.12, and supports Django 4.2 and 5.2. Release cadence is irregular, with minor patches and major version bumps aligned with platform updates.

pip install xblock-drag-and-drop-v2
INSTALL
IMPORT
SIG · XBLOCK-DRAG-AND-DR
X
xblock-drag-and-drop-v2
web-frameworkpythonv5.0.6
Install
9.0s avg
Import
1054ms
Disk
135MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v4.0.3 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 1.062s · 125.2MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 9.0s · import 1.046s · 126MB
135MB installed
● package 135MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

DragAndDropBlock
from drag_and_drop_v2 import DragAndDropBlock
Main XBlock class for drag-and-drop

Quick import test. The block is usually registered via the XBlock runtime in Open edX.

from drag_and_drop_v2 import DragAndDropBlock # The block is typically used within an Open edX course. # Ensure that the XBlock runtime is properly configured. print('Import successful')
Debug
Known issues
breakingPython 3.11 support dropped in v5.0.4; requires Python >=3.12.
fix
Upgrade Python to 3.12 or later.
affects: 5.0.4+
breakingDrop of Python 3.8 in v5.0.0; also added Python 3.12 support.
fix
Use Python 3.9, 3.10, 3.11 (before 5.0.4), or 3.12+.
affects: 5.0.0+
gotchaThe block requires the XBlock runtime to be configured correctly. Simple imports without runtime may fail.
fix
Ensure the XBlock runtime is fully set up, e.g., in Open edX Studio or LMS.
affects: all
Errors
Common errors & fixes
ImportError: No module named 'drag_and_drop_v2'
Library not installed in the Python environment
fix
Run 'pip install xblock-drag-and-drop-v2'
RuntimeError: XBlock runtime not configured
The XBlock runtime is missing or improperly initialized
fix
Use within an Open edX environment or mock the runtime with XBlock SDK.
TypeError: DragAndDropBlock.__init__() got an unexpected keyword argument 'usage_id'
Calling the constructor directly without proper XBlock initialization
fix
The block must be created via the XBlock runtime's 'runtime.construct_xblock' method.
Upgrade
Version history
5.0.6latest on PyPI · released Apr 29, 2026
Audit
Dependencies
XBlockrequiredCore XBlock framework required
DjangorequiredWeb framework, version constraints via Django requirement
Agent activity
32 hits · last 30 days
node
28
OpenAI (training)
1
Resources
xblock-drag-and-drop-v2 — pip install xblock-drag-and-drop-v2 · libregistry