Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

D3.1 phase 2: Switch course-platform readers to courses.LearnerProfile

オープン
#391 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
45/100
issue の種類
リファクタリング
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
django, playwright, python

調査の方向性

D3.1のソース、フェーズ1のissue #390、および一覧にあるview、form、service、APIファイル、galleryモジュールを対象に、grepで裏付けたインベントリから始めます。Djangoのchecksと関連するテストスイートを実行し、galleryのリグレッションテストとPlaywrightのcoreテストも含めます。完了の条件は、10個すべてのフィールドがuser.learner_profileを介して読み書きされ、galleryへのアクセスが固定されたままで、受け入れチェックに合格することです。

索引モデルが issue の本文から書いたものです。

説明

auth courses data-migration enhancement P1

Part of the D3.1 umbrella (#334): phase 2 of 6. Switches the course-platform reader surface for the ten courses.LearnerProfile fields, refreshed against current main.

Normative sources

Source What it governs
community-base repo: docs/plan/phase-3.md D3.1; docs/03-playbooks.md P7 DTC step 3 (reader rewrite) Reader-migration expectation
Phase 1 issue (#390) courses.LearnerProfile model this phase reads/writes

Goal

Every read and write of role, certificate_name, country, region, registration_role, github_url, linkedin_url, personal_website_url, about_me, dark_mode goes through user.learner_profile instead of the CustomUser field. CustomUser's own fields are not removed yet (phase 4) — both are kept in sync so this can land, be verified, and merge on its own before the next reader batch is ready, without blocking on it.

Scope: reader surface (verify each by reading current main, this table is a starting point not exhaustive — grep before finishing)

Area Files
Dark mode course_management/context_processors.py, accounts/views/account_toggles.py
Registration and profile forms courses/views/registration_form.py, courses/views/registration_profile.py, courses/views/forms.py, accounts/forms.py, accounts/views/welcome.py
Projects and API courses/views/project_page_context.py, courses/views/project_submission_edit.py, api/views/enrollment_graduates.py
Member home courses/services/member_home.py
Cross-cohort/site project galleries (new since #334's original grooming, merged to main this cycle) courses/views/project_gallery_groups.py, courses/views/family_project_gallery.py, courses/views/site_project_gallery.py and their templates courses/templates/projects/family_gallery.html, courses/templates/projects/site_gallery.html

Verified read of the gallery module for this issue: as of current main, none of project_gallery_groups.py/family_project_gallery.py/site_project_gallery.py or their templates dereference any CustomUser/LearnerProfile field today — they only group Project/ProjectSubmission by cohort/family and render counts (project.submissions_count, group.projects|length). ProjectSubmission.student is a live FK to the user model (courses/models/project.py, via get_user_model(), not a hardcoded CustomUser import) that this module does not currently dereference. Action for this issue: add a regression test pinning that these three view modules and their templates still resolve zero LearnerProfile/moved-field attribute accesses, so a future change to the gallery that starts rendering submitter role/certificate/links is forced to go through learner_profile from day one instead of reintroducing a CustomUser field read.

Non-goals

  • No change to identity_state/normalized_email readers (phase 3).
  • No removal of the fields from CustomUser (phase 4).
  • No rename (phase 5), no AISL field additions (phase 6).
  • No community_base imports.

Dependencies

  • Depends on: #390 (courses.LearnerProfile must exist and be backfilled).
  • Blocks: #393 (contract removal needs every reader confirmed migrated first).

Acceptance criteria

Django and integration
  • make django-check / make migrations-check pass (no model change expected in this phase; flag if one becomes necessary).
  • make test passes.
  • A grep-backed inventory in the PR body lists every file that read/wrote the ten fields before this change and confirms each now goes through learner_profile.
  • The new gallery-module regression test (above) exists and passes.
  • Writes to dark_mode, certificate_name, profile URLs, about_me, role, registration_role, country/region via the account-settings and registration forms still round-trip through the Django test client.
Browser
  • make test-playwright-core passes: a signed-in member toggles dark mode and the preference survives reload; the registration form still remembers the last-used role.
Repository and operations
  • Versioned verification plan per _docs/ci/change-selective-ci.md recorded in the engineer handoff.
主要言語
Python
スター
0
フォーク
0
PR マージ指標
30日以内にマージされた PR はありません

環境構築

  • Dockerfile または Docker Compose ファイルあり
  • プルリクエストのテンプレートなし
  • コントリビューションガイドなし

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

DataTalksClub/website のほかの issue

DataTalksClub/website の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。