Skip to content

cannot import name 'TypeAlias' from 'typing' Python3.8 fresh install #16

@tomcss

Description

@tomcss

When I try running cast_control, I get the error below. I tried installing through pip (0.11.8
.post0) and from github (0.11.9), but both times I get the same error.

Traceback (most recent call last):
  File "/usr/local/lib/python3.8/dist-packages/mpris_server/types.py", line 5, in <module>
    from typing import \
ImportError: cannot import name 'TypeAlias' from 'typing' (/usr/lib/python3.8/typing.py)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/bin/castctl", line 11, in <module>
    load_entry_point('cast-control==0.11.9', 'console_scripts', 'castctl')()
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 490, in load_entry_point
    return get_distribution(dist).load_entry_point(group, name)
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2854, in load_entry_point
    return ep.load()
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2445, in load
    return self.resolve()
  File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2451, in resolve
    module = __import__(self.module_name, fromlist=['__name__'], level=0)
  File "<frozen zipimport>", line 259, in load_module
  File "/usr/local/lib/python3.8/dist-packages/cast_control-0.11.9-py3.8.egg/cast_control/app/cli.py", line 11, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "/usr/local/lib/python3.8/dist-packages/cast_control-0.11.9-py3.8.egg/cast_control/base.py", line 11, in <module>
  File "/usr/local/lib/python3.8/dist-packages/mpris_server/__init__.py", line 1, in <module>
    from . import adapters, base, types, server, mpris, interfaces
  File "/usr/local/lib/python3.8/dist-packages/mpris_server/adapters.py", line 5, in <module>
    from .base import URI, MIME_TYPES, PlayState, DEFAULT_RATE, Microseconds, \
  File "/usr/local/lib/python3.8/dist-packages/mpris_server/base.py", line 10, in <module>
    from .types import TypedDict, TypeAlias, \
  File "/usr/local/lib/python3.8/dist-packages/mpris_server/types.py", line 11, in <module>
    from typing_extensions import \
ImportError: cannot import name '_GenericAlias' from 'typing_extensions' (/usr/local/lib/python3.8/dist-packages/typing_extensions.py)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions