facebook / pyre-check

Performant type-checking for python.

Home Page:https://pyre-check.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Pyre command hangs on on torch.ao.ns.fx.mappings.get_node_type_to_io_type_map

sumersao opened this issue · comments

I'm getting the following message when running pyre on my codebase.

ƛ The type check of torch.ao.ns.fx.mappings.get_node_type_to_io_type_map is taking more than 1920 seconds (pid = 461].
Is there a way to set a timeout or something? I can't find anything in the documentation -- not really sure how to get around this. Is there a way I can disable the typecheck for this section (idek where this code path is).

@sumersao off I'm sorry to hear that.

There is not currently a way to set a timeout. There are ways to make Pyre not type check the code in question but all of them would require making changes to the function that is causing the problem to convince Pyre it should skip type checking.

I'm a little perplexed though, that function looks like it's part of PyTorch. Unless you're running Pyre on torch itself I wouldn't have expected such code to be type checked. Could you describe your project structure / what does your .pyre_configuration look like?

Sorry never got a notification for your reply.

Yeah we don't directly use torch which is why I was also confused. Using libraries like tiktoken and scikit-learn. I unfortunately don't have the .pyre_configuration anymore, as we went with mypy