Skip to content

decorator with type hint breaks #4173

Open
@lastmjs

Description

@lastmjs

This code runs fine on my machine but not from within RustPython:

from typing import Any

def query(func: Any):
    return func

@query
def hello_world() -> int:
    return 1_000

When you remove the Any type hint the code executes fine in RustPython.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions