Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add lower bound for aiohttp-cors + fix primer #2231

Merged
merged 1 commit into from May 13, 2021

Commits on May 13, 2021

  1. Add lower bound for aiohttp-cors + fix primer

    It appears sqlalchemy has recently reformatted their project with
    Black 21.5b1.
    
    Most of our dependencies have a lower bound and creating a test
    environment with the oldest acceptable dependencies runs the full
    Black test suite just fine. The only exception to this is aiohttp-cors.
    It's unbounded and the oldest version 0.1.0 until 0.4.0 breaks the
    test suite in such an old environment.
    
    Failure with 0.1.0:
    
    ```
    tests/test_blackd.py:10: in <module>
        import blackd
    testenv/lib/python3.8/site-packages/blackd/__init__.py:12: in <module>
        import aiohttp_cors
    testenv/lib/python3.8/site-packages/aiohttp_cors/__init__.py:29: in <module>
        from .urldispatcher_router_adapter import UrlDistatcherRouterAdapter
    testenv/lib/python3.8/site-packages/aiohttp_cors/urldispatcher_router_adapter.py:27: in <module>
        class UrlDistatcherRouterAdapter(RouterAdapter):
    testenv/lib/python3.8/site-packages/aiohttp_cors/urldispatcher_router_adapter.py:32: in UrlDistatcherRouterAdapter
        def route_methods(self, route: web.Route):
    E   AttributeError: module 'aiohttp.web' has no attribute 'Route'
    ```
    
    For 0.2.0:
    
    ```
    tests/test_blackd.py:10: in <module>
        import blackd
    testenv/lib/python3.8/site-packages/blackd/__init__.py:12: in <module>
        import aiohttp_cors
    testenv/lib/python3.8/site-packages/aiohttp_cors/__init__.py:27: in <module>
        from .cors_config import CorsConfig
    testenv/lib/python3.8/site-packages/aiohttp_cors/cors_config.py:24: in <module>
        from .urldispatcher_router_adapter import UrlDistatcherRouterAdapter
    testenv/lib/python3.8/site-packages/aiohttp_cors/urldispatcher_router_adapter.py:27: in <module>
        class UrlDistatcherRouterAdapter(AbstractRouterAdapter):
    testenv/lib/python3.8/site-packages/aiohttp_cors/urldispatcher_router_adapter.py:32: in UrlDistatcherRouterAdapter
        def route_methods(self, route: web.Route):
    E   AttributeError: module 'aiohttp.web' has no attribute 'Route'
    ```
    
    For 0.3.0:
    
    ```
    ERROR: Cannot install aiohttp-cors==0.3.0 and aiohttp==3.6.0 because these package versions have conflicting dependencies.
    
    The conflict is caused by:
        The user requested aiohttp==3.6.0
        aiohttp-cors 0.3.0 depends on aiohttp<=0.20.2 and >=0.18.0
    
    To fix this you could try to:
    1. loosen the range of package versions you've specified
    2. remove package versions to allow pip attempt to solve the dependency conflict
    
    ERROR: ResolutionImpossible: for help visit https://pip.pypa.io/en/latest/user_guide/#fixing-conflicting-dependencies
    ```
    ichard26 committed May 13, 2021
    Copy the full SHA
    b3c6f06 View commit details
    Browse the repository at this point in the history