Skip to content

ImportError: cannot import name 'unquote' #2662

Closed
@ilmaruk

Description

Long story short

As of yarl 1.0.0 (available since one hour ago), yarl.unquote is no longer available, thus causing an import error at web_urldispatcher.py.

Expected behaviour

Been able to run: from aiohttp import web

Actual behaviour

from aiohttp import web raises the following error:

  File "web.py", line 1, in <module>
    from aiohttp import web
  File "/home/ruggero/Development/mqtt/.venv/lib/python3.6/site-packages/aiohttp/web.py", line 15, in <module>
    from . import (hdrs, web_exceptions, web_fileresponse, web_middlewares,
  File "/home/ruggero/Development/mqtt/.venv/lib/python3.6/site-packages/aiohttp/web_middlewares.py", line 5, in <module>
    from aiohttp.web_urldispatcher import SystemRoute
  File "/home/ruggero/Development/mqtt/.venv/lib/python3.6/site-packages/aiohttp/web_urldispatcher.py", line 21, in <module>
    from yarl import URL, unquote
ImportError: cannot import name 'unquote'

Steps to reproduce

Simply: from aiohttp import web

Your environment

aiohttp 2.3.7 (both)
Ubuntu Linux 16.04
Python 3.6.3

Workaround

Downgrade to yarl 0.18.0

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions