Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

A GitHub Action to run pyright

License

NotificationsYou must be signed in to change notification settings

jordemort/action-pyright

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Repository files navigation

testdepupreleaseGitHub release (latest SemVer)action-bumpr supported

This is an action that runs thepyright type checker against your Python code, and usesreviewdog to create GitHub PR comments or reviews with the results.

screenshot

This action is based onaction-eslint and inspired bypyright-action.

You can configure pyright usingpyrightconfig.json orpyproject.toml, or see the inputs below.

Example usage

name:reviewdogon:[pull_request]jobs:pyright:name:pyrightruns-on:ubuntu-lateststeps:      -uses:actions/checkout@v2      -uses:jordemort/action-pyright@v1with:github_token:${{ secrets.GITHUB_TOKEN }}# You need thisreporter:github-pr-review# Change reporter.lib:true

Inputs

github_token

Required. Default is${{ github.token }}.

level

Optional. Report level for reviewdog [info,warning,error].It's same as-level flag of reviewdog.

reporter

Reporter of reviewdog command [github-pr-check,github-check,github-pr-review].Default is github-pr-review.It's same as-reporter flag of reviewdog.

filter_mode

Optional. Filtering mode for the reviewdog command [added,diff_context,file,nofilter].Default is added.

fail_on_error

Optional. Exit code for reviewdog when errors are found [true,false]Default isfalse.

reviewdog_flags

Optional. Additional reviewdog flags

workdir

Optional. The directory from which to run pyright. Default '.'

pyright_version

Optional. Version of pyright to run. If not specified, the latest version will be used.

python_platform

Optional. Analyze for a specific platform (Darwin, Linux, Windows)

python_version

Optional. Analyze for a specific Python version (3.3, 3.4, etc.)

typeshed_path

Optional. Use typeshed type stubs at this location.

venv_path

Optional. Directory that contains virtual environments.

project

Optional. Use the configuration file at this location.

lib

Optional. Use library code to infer types when stubs are missing. Defaultfalse.

pyright_flags

Optional extra arguments; can be used to specify specific files to check.


[8]ページ先頭

©2009-2025 Movatter.jp