8000 Initial tensorflow stubs by hmc-cs-mdrissi · Pull Request #8974 · python/typeshed · GitHub
[go: up one dir, main page]

Skip to content

Initial tensorflow stubs #8974

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 22 commits into from
Jan 14, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
[pre-commit.ci] auto fixes from pre-commit.com hooks
  • Loading branch information
pre-commit-ci[bot] committed Jan 11, 2023
commit 9e01dde80a20f9514384a428b77b84656687352b
12 changes: 10 additions & 2 deletions tests/mypy_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,12 +79,20 @@ def valid_path(cmd_arg: str) -> Path:
description="Typecheck typeshed's stubs with mypy. Patterns are unanchored regexps on the full path."
)
if sys.version_info < (3, 8):

class ExtendAction(argparse.Action):
def __call__(self, parser: argparse.ArgumentParser, namespace: argparse.Namespace, values: Sequence[str], option_string: object = None) -> None:
def __call__(
self,
parser: argparse.ArgumentParser,
namespace: argparse.Namespace,
values: Sequence[str],
option_string: object = None,
) -> None:
items = getattr(namespace, self.dest) or []
items.extend(values)
setattr(namespace, self.dest, items)
parser.register('action', 'extend', ExtendAction)

parser.register("action", "extend", ExtendAction)
parser.add_argument(
"filter",
type=valid_path,
Expand Down
0