refactor(reorg): extract survey + benchmark modules [8/10]#14983
Draft
valentijnscholten wants to merge 1 commit into
Draft
refactor(reorg): extract survey + benchmark modules [8/10]#14983valentijnscholten wants to merge 1 commit into
valentijnscholten wants to merge 1 commit into
Conversation
…ojo/<module>/ [Phase 1,3,4,5]
This was referenced Jun 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked PRs
This is one of a stacked series that reorganizes
dojo/into self-containeddojo/{module}/packages (matching thedojo/url/reference). They are stacked — each PR is based on the previous one — so review and merge bottom-up in this order:Merge #14970 first; each following branch is rebased onto the updated base and merged in turn. This PR continues the stack on top of #14982 — full implementation brief is the Phase 10 section in
AGENTS.md.Summary
Reorganizes the
surveyandbenchmarkdomains into self-containeddojo/survey/anddojo/benchmark/packages with aui/sub-package, matching thedojo/url/reference layout. Neither domain has anyapi_v2serializers/viewsets, so there is noapi/layer (Phases 6–9 skipped). Pure code-movement: no behaviour or migration changes; backward-compat re-exports keep external consumers working.benchmark (
dojo/benchmark/)Benchmark_Type,Benchmark_Category,Benchmark_Requirement,Benchmark_Product,Benchmark_Product_Summaryintodojo/benchmark/{models,admin}.py. All FKs use string refs;Benchmark_Requirement.cwe_mappingreferences"dojo.CWE"(CWE lives indojo/finding/, re-exported fromdojo.models).ui/forms.py(re-exported fromdojo/forms.pyfor external consumers). Moveviews.py/urls.pyintoui/;signals.pystays.survey (
dojo/survey/)Question,TextQuestion,Choice,ChoiceQuestion,Engagement_Survey,Answered_Survey,General_Survey,Answer,TextAnswer,ChoiceAnswer) intodojo/survey/{models,admin}.py. TheQuestionandAnswerbase classes keep theirwith warnings.catch_warnings(action="ignore", category=ManagerInheritanceWarning):wrapping. All FKs use string refs;get_form()lazy-imports the question forms fromdojo.survey.ui.forms.ui/forms.py(including the survey-specificMultiWidgetBasic/MultiExampleFieldand the now-single-sourcedMultipleSelectWithPopwidget, removed as dead code fromdojo/forms.py), andQuestionnaireFilter/QuestionTypeFilterintoui/filters.py. Moveviews.py/urls.pyintoui/.