DRU-663 -- Name subjects with __str__ and let a model declare its order - #738
Merged
czpython merged 1 commit intoSep 27, 2026
Conversation
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Automations to automatically generate PRs for you. |
czpython
force-pushed
the
commonzenpython/dru-663-name-subjects-with-__str__-and-let-a-model-declare-its-order
branch
from
September 27, 2026 16:25
10c0ec8 to
32a6824
Compare
A subject's __str__ is its name on runs, events, the Activity feed, and its
board, replacing get_key(); the default stays its type and id. The subject
title goes from runs, events, the feed and its search, and SubjectSummary,
and summary_class goes with it: the platform builds its header from the id
and the name, and an app with its own frontend overrides get_summary().
A model declares its order on the class line in Django's form,
class Report(Model, ordering=("-created_at",)), and filter and the default
board follow it. A Literal column is stored under a CHECK of its values, like
a StrEnum. An identity-only Subject answers get(id), which raises
ObjectNotFound like Model.get, and a page for a missing subject links back to
its parent page or the app's landing page.
Gate.answer and Workflow.cancel read their run through
Run.get_latest_for_subject, which can narrow to the gate a run is parked on.
Software Factory builds a pull request subject with PullRequest(id=...), and a
work item names itself with its ticket key and title.
czpython
force-pushed
the
commonzenpython/dru-663-name-subjects-with-__str__-and-let-a-model-declare-its-order
branch
from
September 27, 2026 16:43
32a6824 to
8a10552
Compare
czpython
deleted the
commonzenpython/dru-663-name-subjects-with-__str__-and-let-a-model-declare-its-order
branch
September 27, 2026 16:48
This branch was successfully deployed
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.
A subject's
__str__is its name on runs, events, the Activity feed, and its board, replacingget_key(). The default stays its type and id, such asnote 7.SubjectSummary, andsummary_classgoes with it. The platform builds its header from the id and the name; an app with its own frontend overridesget_summary().filterand the default board follow it.Literalcolumn is stored under a CHECK of its values, like aStrEnum.Subjectanswersget(id), which raisesObjectNotFoundlikeModel.get.Gate.answerandWorkflow.cancelread their run throughRun.get_latest_for_subject, which can narrow to the gate a run is parked on.PullRequest(id=...), and a work item names itself with its ticket key and title.