Skip to content

Commit 6cf0c46

Browse files
authored
Merge pull request #423 from datacamp/cp-4791-fix-typed-signature-validation
[CP-4791] Fix typed signature validation
2 parents 1bad936 + 9fbbeb3 commit 6cf0c46

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pythonwhat/tasks.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,8 @@ def get_signature(name, mapped_name, signature, manual_sigs, env):
134134
except:
135135
raise InstructorError.from_message(e.args[0] + " and cannot determine signature")
136136

137-
return signature
137+
params = [param.replace(annotation=inspect._empty) for param in signature.parameters.values()]
138+
return signature.replace(parameters=params)
138139

139140

140141
# Get the signature of a function based on an object inside the process

0 commit comments

Comments
 (0)