-
Notifications
You must be signed in to change notification settings - Fork 198
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3b39021
commit d75f1c3
Showing
61 changed files
with
1,127 additions
and
972 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
from mypy.plugin import FunctionContext, Plugin | ||
from mypy.types import Type | ||
|
||
def plugin(v): | ||
return ParslMypyPlugin | ||
|
||
class ParslMypyPlugin(Plugin): | ||
def get_type_analyze_hook(self, t): | ||
# print("BENC: gtah t={}".format(t)) | ||
return None | ||
|
||
def get_function_hook(self, f): | ||
if f == "parsl.app.errors.wrap_error": | ||
return wrap_error_hook | ||
else: | ||
return None | ||
|
||
def wrap_error_hook(ctx: FunctionContext) -> Type: | ||
print("inside wrap_error_hook for parsl-mypy") | ||
print("ctx = {}".format(ctx)) | ||
print("ctx.default_return_type = {}".format(ctx.default_return_type)) | ||
return ctx.default_return_type |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.