Repository navigation
feat(comments): make the comment dialect configurable per connection - #148
Merged
Merged
Conversation
Descriptions run through the dialect converter while comments were always posted raw, so one written dialect meant two different things depending on the target field. The connection gains comment_dialect (markdown|wiki); the default 'wiki' preserves the historical raw behaviour exactly, and an instance whose authors write Markdown in comments as well can now serve both fields with one written dialect. comment add/update accept --dialect to deviate for a single call; the --embed ADF path stays verbatim. The asymmetry becomes configurable rather than reversed. The conversion reuses render_description, keeping one text-to-wiki path that a future ADF wire format (epic #96) can sit behind. The settings serializer whitelists connection fields for TOML and learned the new key; old connections.toml files load unchanged via the model default. Closes #134
Regenerate .claude/ai-usage-prompt.md after the configurable comment dialect (comment_dialect, --dialect on comment add/update).
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.
Why (from #134, measured 2026-09-20)
Descriptions and comments take different upload paths: descriptions are converted per
description_dialect, comments were posted raw. The same source text therefore rendered differently depending on the target field — a Markdown list in a comment stayed literal. On instances where API-posted comments cannot be edited, the first shot is the only shot.What
comment_dialect(markdown|wiki), settable viabudjira connect add --comment-dialect, shown byconnect add/connect show.budjira comment addandcomment updateaccept--dialectto deviate for a single call (analogous to--description-dialect).--embedpath posts ADF (REST v3) verbatim; no dialect applies there — documented in help, README and the AI prompt.render_description: one text-to-wiki path, signature untouched (the external checker script keeps working), and the authored dialect is a connection property with the wire format behind it — the shape epic Epic: Migrate jira-python client from REST API v2 to v3 (ADF) #96 (ADF) needs.Default / compatibility
Default is
wiki— the historical raw behaviour, bit-identical. Existing connections keep working unchanged: the TOML serializer learned the new key, and oldconnections.tomlfiles load via the model default. The asymmetry becomes configurable, not reversed: descriptions defaultmarkdown, comments defaultwiki, and an instance that differs per field stays representable.Which dialect applies where: descriptions follow
description_dialect, comments followcomment_dialect; the CLI override wins over the connection setting in both cases. This sentence is now in the README and inutils/description.py's module docstring — the trap #134 grew out of.Tests
--dialectoverride wins, embed path applies no dialect; existing comment tests migrated from the deprecated facade tocomments.add(the CLI now passes the dialect through the service layer directly).wiki; model default test;connect addstores and defaults correctly (2 tests).budjira ai usage-prompt --plainoutput checked; regenerated prompt committed separately.Closes #134