Skip to content

Issue with type definitions in types.py #1

@ask53

Description

@ask53

Hey Jos, when i installed tabularjson with pip and tried to import it into my project, i got the following error message:

"Traceback (most recent call last):
File "<pyshell#3>", line 1, in
import tabularjson
File "[TABULAR JSON LOCAL PATH]_init_.py", line 1, in
from tabularjson.stringify import stringify
File "[TABULAR JSON LOCAL PATH]\stringify.py", line 6, in
from tabularjson.objects import get_in
File "[TABULAR JSON LOCAL PATH]\objects.py", line 3, in
from tabularjson.types import Path, Record
File "[TABULAR JSON LOCAL PATH]\types.py", line 14
type Path = list[str | int]
^^^^
SyntaxError: invalid syntax

Wondering if you have any thoughts for what's going on. I've never worked with preemptively declaring the types of python variables, so not sure what the syntax error is. Thank you!!!

Metadata

Metadata

Assignees

No one assigned

    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