Repository navigation
fix(ticket): auto_introtext + ticket_max_cut (#218) - #219
Draft
Ibochkarev wants to merge 1 commit into
Draft
Ibochkarev wants to merge 1 commit into
Ibochkarev wants to merge 1 commit into
Conversation
With auto_introtext on, web saves no longer die on missing <cut/> past ticket_max_cut: insert the tag at that length and build introtext from the teaser. Centralize cut/introtext helpers on Ticket; processors and save() reuse them. Closes #218
Ibochkarev
force-pushed
the
fix/issue-218-auto-introtext-max-cut
branch
from
September 9, 2026 15:49
86d9f12 to
830400e
Compare
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.
Summary
tickets.auto_introtextenabled, web create/update pasttickets.ticket_max_cutwithout<cut/>inserts the cut at that length instead of returningticket_err_cut, so introtext can fill from the teaser.getIntroText()caps teasers toticket_max_cut(and recovers from an empty teaser when cut is at the start).Ticket(prepareWebContent,resolveIntrotext,ensureAutoIntrotext); create/update processors andsave()call it once.Closes #218
Test plan
tickets.auto_introtext=Да,tickets.ticket_max_cut=500: create ticket on web with >500 chars, no<cut/>→ save OK, introtext ≈ first 500 chars, content contains<cut/>auto_introtext=Нет→ stillticket_err_cut<cut/>→ introtext = text before cut (unchanged)