Skip to content

Commit 72c0a02

Browse files
author
David Robertson
committed
Allow extras to be installed for typechecking
1 parent 9588c2b commit 72c0a02

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

.github/workflows/python-poetry-ci.yml

+14
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,17 @@
11
name: Linting
22
on:
33
workflow_call:
4+
inputs:
5+
extras:
6+
description: >
7+
Space-separated list of extras to install when type checking.
8+
Defaults to no extras.
9+
# In the future I'd like to change setup-python-poetry to install all extras
10+
# by default, using e.g. an implementation of
11+
# https://github.com/python-poetry/poetry/issues/3413
12+
type: string
13+
required: false
14+
default: ""
415

516

617
jobs:
@@ -33,6 +44,9 @@ jobs:
3344

3445
- name: Setup Poetry
3546
uses: matrix-org/setup-python-poetry@v1
47+
with:
48+
# We want to make use of type hints in optional dependencies too.
49+
extras: "${{ inputs.extras }}"
3650

3751
- name: Restore/persist mypy's cache
3852
uses: AustinScola/mypy-cache-github-action@v1

0 commit comments

Comments
 (0)