Skip to content

Adopt the yard-lint 1.10 documentation standard - #943

Merged
mensfeld merged 1 commit into
masterfrom
yard-lint-1.10-standard
Jul 26, 2026
Merged

Adopt the yard-lint 1.10 documentation standard#943
mensfeld merged 1 commit into
masterfrom
yard-lint-1.10-standard

Conversation

@mensfeld

Copy link
Copy Markdown
Member

Bring rdkafka-ruby in line with the karafka/mensfeld yard-lint standard:

  • Bump yard-lint 1.4.0 -> 1.10.3 (Gemfile.lint.lock)
  • Enable new cops as errors:
    • Documentation/DuplicateNamespaceComment
    • Documentation/UnderfilledLines (MaxLength 100, matching RuboCop Layout/LineLength)
    • Documentation/LineLength (MaxLength 100)
    • Documentation/TextSubstitution (em/en-dash -> hyphen)
  • Promote Tags/ExampleSyntax from warning to error
  • Expand Tags/Order to the ecosystem-wide order (param, option, yield*, return, raise, see, example, note, todo)
  • Fix all resulting documentation offenses: reflow over-long doc lines and underfilled paragraphs, reorder tag blocks, and convert two genuinely orphaned FFI attach_function tag comments (@see / @param) to prose.

Comment-only changes in lib/**; no Ruby code was modified.

Note: yard-lint 1.10.3 also fixes an OrphanedDocComment false positive on class variable doc comments (mensfeld/yard-lint#293), which rdkafka relies on for its internal '# @Private' + '@@var' markers.

Bring rdkafka-ruby in line with the karafka/mensfeld yard-lint standard:

- Bump yard-lint 1.4.0 -> 1.10.2 (Gemfile.lint.lock)
- Enable new cops as errors:
  - Documentation/DuplicateNamespaceComment
  - Documentation/UnderfilledLines (MaxLength 100, matching RuboCop Layout/LineLength)
  - Documentation/LineLength (MaxLength 100)
  - Documentation/TextSubstitution (em/en-dash -> hyphen)
- Promote Tags/ExampleSyntax from warning to error
- Expand Tags/Order to the ecosystem-wide order
  (param, option, yield*, return, raise, see, example, note, todo)
- Fix all resulting documentation offenses: reflow over-long doc lines and
  underfilled paragraphs, reorder tag blocks, and convert two genuinely
  orphaned FFI attach_function tag comments (@see / @param) to prose.
- Express internal class-variable visibility markers with the
  '@!visibility private' directive instead of the bare '@Private' tag, so
  YARD keeps hiding them without OrphanedDocComment flagging the doc comment
  (the tag form is folded onto a class-variable assignment, which the cop
  treats as orphaned).

Comment-only changes in lib/**; no Ruby code was modified.
'bundle exec yard-lint lib' and 'bundle exec rubocop' both pass locally.
@mensfeld
mensfeld force-pushed the yard-lint-1.10-standard branch from 3bd7b8d to 6d9288a Compare July 25, 2026 20:42
@mensfeld mensfeld self-assigned this Jul 26, 2026
@mensfeld
mensfeld marked this pull request as ready for review July 26, 2026 10:42
@mensfeld
mensfeld merged commit a1e7612 into master Jul 26, 2026
97 checks passed
@mensfeld
mensfeld deleted the yard-lint-1.10-standard branch July 26, 2026 10:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant