Skip to content
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

Fix python 3.8 runtime type error #9502

Merged
merged 1 commit into from Apr 10, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/python/pants/rules/core/test.py
Expand Up @@ -109,7 +109,7 @@ def create(cls, target_with_origin: TargetWithOrigin) -> "TestConfiguration":
all_expected_fields: Dict[str, Type[Field]] = {
dataclass_field.name: dataclass_field.type
for dataclass_field in dataclasses.fields(cls)
if issubclass(dataclass_field.type, Field)
if isinstance(dataclass_field.type, type) and issubclass(dataclass_field.type, Field) # type: ignore[misc]
}
tgt = target_with_origin.target
return cls(
Expand Down