← Back to Pull requests

Remove ruff-enforced style rules and fix stale references in developer guidelines #1885

Closed
unknown closed this pull request without merging on Oct 09, 2026 15:38 UTC
View on GitHub
unknown unknown commented on Oct 07, 2026 10:53 UTC
Author

Part of #1829.

This PR implements the scope that I proposed in https://github.com/brian-team/brian2/issues/1829#issuecomment-4995656539 (items A to C) and also fixes a few stale references that I found while re-checking the pages against master. It does not restructure the guidelines and does not add a CONTRIBUTING.md or templates (see #1830).

style.rst

  • The list of PEP-8 rules (indentation, spaces around operators and in keyword arguments, backslash continuations) is removed. ruff format, which the page already names as the tool that enforces the code style, applies all of them; I checked this with ruff 0.14.2 (the version pinned in .pre-commit-config.yaml) and the repository's pyproject.toml. Apart from the link below, the rest of the page, including the import conventions, is unchanged.

  • The link to Romain Brette's paper (a PDF on briansimulator.org) returns 404. It now points to the DOI of the published article and uses its exact title ("On the design of script languages for neural simulation").
  • workflow.rst

  • "if a commit not touches any code files" is corrected to "does not touch".

  • https://help.github.com/articles/using-pull-requests is replaced by https://docs.github.com/en/pull-requests (the old URL now only redirects).

  • The coveralls link is still current and is unchanged.
  • testing.rst

  • numpy.testing.utils was removed in NumPy 1.25, and numpy.testing has no array_equal function. The text now refers to numpy.testing.assert_array_equal, and the two examples import assert_equal from numpy.testing, as the test suite does. I also removed "types" from "comparing types, shapes and content", since assert_array_equal compares dtypes only with strict=True.

  • The doctest documentation link pointed to the Python 2 documentation; it now points to the Python 3 page.
  • representation.rst

  • The link to the IPython pretty printer documentation on ipython.org returns 404; it now points to the same section on ipython.readthedocs.io.
  • The code_style anchor is kept, since the release notes refer to it.

    Checks: rstcheck reports no issues on the four files (for representation.rst, with Sphinx's doctest directive ignored, since rstcheck does not recognise it). sphinx-build -b html succeeds on master and on this branch with the same set of warnings, and the new NumPy references resolve through intersphinx.

    Diff: 300 lines (+225 / -75) across 3 files Reviewer: mstimberg Review duration: 3165m
    All Vouch review confidence checks passed
    Residual risk 0.16 = Change Risk (0.40) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.40 · 300 lines diff across 3 files
    0.40
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.341
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #1885"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 40.1% (MEDIUM) · Higher = larger blast radius
    40.1%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 15.8% · Safe to merge
    15.8%