{"id":23084,"library":"edx-when","title":"edx-when","description":"A Django app for managing content scheduling and due dates in Open edX courses. It provides models and APIs for content dates, user-specific overrides, and schedule computation. Current version 4.0.0 (released 2025-05-07). Release cadence: irregular, with major version bumps when dropping Python/Django support.","status":"active","version":"4.0.0","language":"python","source_language":"en","source_url":"https://github.com/openedx/edx-when","tags":["edx","openedx","django","scheduling","due-dates"],"install":[{"cmd":"pip install edx-when","lang":"bash","label":"Install from PyPI"}],"dependencies":[{"reason":"Models and migrations depend on Django ORM","package":"Django","optional":false},{"reason":"UsageKey types for block identifiers","package":"edx-opaque-keys","optional":false}],"imports":[{"wrong":"from edx_when.models import ContentDate","symbol":"ContentDate","correct":"from edx_when.models import ContentDate"}],"quickstart":{"code":"import os\nos.environ.setdefault('DJANGO_SETTINGS_MODULE', 'yourproject.settings')\n\nimport django\ndjango.setup()\n\nfrom django.contrib.auth import get_user_model\nfrom opaque_keys.edx.keys import CourseKey\nfrom edx_when.api import get_schedule_for_user\n\ndef demo():\n    user = get_user_model().objects.first()\n    course_key = CourseKey.from_string('course-v1:DemoX+Demo_2024')\n    schedule = get_schedule_for_user(user.id, course_key)\n    print(schedule[:3] if schedule else 'No schedule found')\n\ndemo()","lang":"python","description":"Fetches the first 3 schedule entries for a given user and course. Requires Django settings configured."},"warnings":[{"fix":"Upgrade to Python 3.12+ or pin to edx-when<4.0.0.","message":"Version 4.0.0 drops support for Python 3.11. You must use Python 3.12+. Check your deployment.","severity":"breaking","affected_versions":">=4.0.0"},{"fix":"Upgrade to Python 3.9+ or use edx-when<3.0.0.","message":"Version 3.0.0 drops support for Python 3.8 and adds Python 3.12 support. Existing Python 3.8 deployments will break.","severity":"breaking","affected_versions":">=3.0.0,<4.0.0"},{"fix":"Use user.id and course_key. Convert course strings with CourseKey.from_string().","message":"The get_schedule_for_user function requires a User ID (integer) and CourseKey; passing a username or course string will raise an AttributeError.","severity":"gotcha","affected_versions":"all"}],"env_vars":null,"search_vec":"'-05':38 '-07':39 '2025':37 '4.0.0':35 'api':22 'app':6 'bump':46 'cadenc':41 'comput':32 'content':9,24 'cours':17 'current':33 'date':13,25,57 'django':5,53 'drop':48 'due':12,56 'due-dat':55 'edx':2,16,51 'edx-when':1 'irregular':42 'major':44 'manag':8 'model':20 'open':15 'openedx':52 'overrid':29 'provid':19 'python/django':49 'releas':36,40 'schedul':10,31,54 'specif':28 'support':50 'user':27 'user-specif':26 'version':34,45","created_at":"2026-05-01T06:02:21.085853+00:00","updated_at":"2026-05-01T06:02:21.085853+00:00","problems":{"verify_error":"Traceback (most recent call last):\n  File \"<string>\", line 1, in <module>\n  File \"/tmp/tmp9926mues/venv/lib/python3.12/site-packages/edx_when/models.py\", line 11, in <module>\n    from model_utils.models import TimeStampedModel\n  File \"/tmp/tmp9926mues/venv/lib/python3.12/site-packages/model_utils/mo"},"ecosystem":"pypi","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":"4.0.0","cli_name":"","cli_version":null,"type":"library","homepage":null,"github":"https://github.com/openedx/edx-when","docs":null,"changelog":null,"pypi":"https://pypi.org/project/edx-when/","npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["web-framework","database"],"base_url":null,"auth_type":null,"provenance":{"verified_status":"import_fail","verified_at":"2026-07-03","last_verified":"2026-07-03","next_check":"2026-07-10","install_tag":null}}