Skip to content

chore: Update coderabbitai configuration to not expect docstrings in test#1355

Merged
Czaki merged 1 commit intodevelopfrom
update_coderabbit_config
Feb 12, 2026
Merged

chore: Update coderabbitai configuration to not expect docstrings in test#1355
Czaki merged 1 commit intodevelopfrom
update_coderabbit_config

Conversation

@Czaki
Copy link
Collaborator

@Czaki Czaki commented Feb 11, 2026

#1352 (comment)

Summary by Sourcery

Build:

  • Update CodeRabbit configuration to exempt Python test files from requiring docstrings.

Summary by CodeRabbit

  • Chores
    • Updated code review configuration to clarify that docstrings are not required for test functions in test files.

@sourcery-ai
Copy link
Contributor

sourcery-ai bot commented Feb 11, 2026

Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Updates the CodeRabbit configuration to exempt Python test files from the requirement to have docstrings, by adding a path-specific review instruction for test paths under package/tests.

Flow diagram for CodeRabbit review behavior with test file docstring exemption

flowchart TD
    A[PR opened or updated] --> B[CodeRabbit reads .coderabbit.yaml]
    B --> C[Identify changed files]
    C --> D{File matches path pattern<br/>package/tests/**/*.py?}
    D -- Yes --> E[Apply path_instructions<br/>for test files]
    E --> F[Do not enforce<br/>docstring requirement<br/>on test functions]
    F --> G[Run other enabled<br/>review checks]
    D -- No --> H[Apply default<br/>review instructions]
    H --> I[Enforce docstring<br/>requirement where applicable]
    I --> G
    G --> J[Publish GitHub check<br/>with review results]
Loading

File-Level Changes

Change Details Files
Configure CodeRabbit so test Python files no longer require docstrings.
  • Extend the reviews configuration in .coderabbit.yaml with a path_instructions section.
  • Add a rule targeting package/tests/**/*.py test files.
  • Specify that docstrings are not required for test functions in the matched test files.
.coderabbit.yaml

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 11, 2026

Warning

Ignoring CodeRabbit configuration file changes. For security, only the configuration from the base branch is applied for open source repositories.

📝 Walkthrough

Walkthrough

A new path_instructions configuration entry is added to .coderabbit.yaml specifying that docstrings are not required for test functions in test files under package/tests/**/*.py.

Changes

Cohort / File(s) Summary
Configuration Update
.coderabbit.yaml
Added new top-level path_instructions field with one entry exempting test files under package/tests/**/*.py from requiring docstrings on test functions.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Suggested labels

skip check PR title

Poem

🐰 A tiny config tweak, so neat and small,
Tests need no docstrings, not needed at all,
Path instructions guide the way,
Making reviews lighter today!

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: updating CodeRabbit configuration to exclude docstring requirements for test files.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch update_coderabbit_config

No actionable comments were generated in the recent review. 🎉


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@sonarqubecloud
Copy link

@Czaki Czaki changed the title chore:Update coderabbitai configuration to not expect docstrings in test chore: Update coderabbitai configuration to not expect docstrings in test Feb 11, 2026
@Czaki Czaki added the skip check PR title skip spellcheking PR title label Feb 11, 2026
@Czaki Czaki added this to the 0.16.5 milestone Feb 12, 2026
@Czaki Czaki merged commit 5f220a1 into develop Feb 12, 2026
59 of 64 checks passed
@Czaki Czaki deleted the update_coderabbit_config branch February 12, 2026 07:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip check PR title skip spellcheking PR title

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant