Skip to content

feat(typings): Add pyrefly type checker#101

Draft
tkislan wants to merge 4 commits into
mainfrom
tk/add-pyrefly-type-check
Draft

feat(typings): Add pyrefly type checker#101
tkislan wants to merge 4 commits into
mainfrom
tk/add-pyrefly-type-check

Conversation

@tkislan
Copy link
Copy Markdown
Contributor

@tkislan tkislan commented May 18, 2026

Summary by CodeRabbit

  • Chores
    • Added a CI step to run an additional static-check tool as part of existing type-checking.
    • Added that static-check tool to development dependencies and added project-level configuration for its operation.
    • Added a baseline file to record and suppress existing diagnostics for the new checks, reducing noise from preexisting issues.

Review Change Stack

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 18, 2026

Caution

Review failed

Failed to post review comments

📝 Walkthrough

Walkthrough

This PR integrates pyrefly, a type-checking tool, into the deepnote-toolkit CI pipeline. The changes add pyrefly as a dev dependency, configure it in pyproject.toml with project scope and error mappings that mirror the existing mypy checks, establish a baseline JSON file documenting pre-existing type diagnostics across four modules, and wire a new CI step into the mypy job to run pyrefly checks post-build.

Sequence Diagram(s)

sequenceDiagram
  participant GitHubActions
  participant pyrefly
  participant Repository
  GitHubActions->>Repository: checkout
  GitHubActions->>pyrefly: poetry run pyrefly check --output-format min-text
  pyrefly->>Repository: load [tool.pyrefly] config and pyrefly-baseline.json
  pyrefly->>GitHubActions: emit min-text diagnostics
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

🚥 Pre-merge checks | ✅ 5 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Updates Docs ❓ Inconclusive Repository clone failed, so this custom check could not run with code access. Retry the review run. If this persists, inspect pre-merge custom-check logs for infrastructure or agent runtime failures.
✅ Passed checks (5 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 objective: adding pyrefly, a type checker, to the project.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

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


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

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 18, 2026

📦 Python package built successfully!

  • Version: 2.3.0.dev7+7ede6b6
  • Wheel: deepnote_toolkit-2.3.0.dev7+7ede6b6-py3-none-any.whl
  • Install:
    pip install "deepnote-toolkit @ https://deepnote-staging-runtime-artifactory.s3.amazonaws.com/deepnote-toolkit-packages/2.3.0.dev7%2B7ede6b6/deepnote_toolkit-2.3.0.dev7%2B7ede6b6-py3-none-any.whl"

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/ci.yml:
- Around line 211-214: The "Run pyrefly" workflow step currently runs without an
explicit condition so it uses the default if: success() and can be skipped after
mypy failures; update the step that runs "poetry run pyrefly check
--output-format min-text" (the step named "Run pyrefly") to include if: always()
so pyrefly diagnostics are executed and reported regardless of previous job
status.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: bdf45fdd-663c-40c5-a98f-9920b0a1be48

📥 Commits

Reviewing files that changed from the base of the PR and between 8bb3cef and 8b4c6b3.

⛔ Files ignored due to path filters (1)
  • poetry.lock is excluded by !**/*.lock
📒 Files selected for processing (3)
  • .github/workflows/ci.yml
  • pyproject.toml
  • pyrefly-baseline.json

Comment thread .github/workflows/ci.yml
@codecov
Copy link
Copy Markdown

codecov Bot commented May 18, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 74.09%. Comparing base (98e2371) to head (e9e04c8).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #101   +/-   ##
=======================================
  Coverage   74.09%   74.09%           
=======================================
  Files          95       95           
  Lines        5678     5678           
  Branches      843      843           
=======================================
  Hits         4207     4207           
  Misses       1195     1195           
  Partials      276      276           
Flag Coverage Δ
combined 74.09% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@deepnote-bot
Copy link
Copy Markdown

deepnote-bot commented May 18, 2026

🚀 Review App Deployment Started

📝 Description 🌐 Link / Info
🌍 Review application ra-101
🔑 Sign-in URL Click to sign-in
📊 Application logs View logs
🔄 Actions Click to redeploy
🚀 ArgoCD deployment View deployment
Last deployed 2026-05-28 09:46:53 (UTC)
📜 Deployed commit 20c85fd7d7738fb004cf748cb98cb2a77d235c02
🛠️ Toolkit version 7ede6b6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants