Skip to content

Commit bba92a8

Browse files
committed
Add type annotation for fix_url_for
I have no clue why this doesn't fail type checking since we don't have a hint for app.legacy_mapper, but ok.
1 parent 322326e commit bba92a8

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

lib/galaxy/webapps/galaxy/api/__init__.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,10 @@
4141
from fastapi_utils.inferring_router import InferringRouter
4242
from pydantic import ValidationError
4343
from pydantic.main import BaseModel
44-
from routes import request_config
44+
from routes import (
45+
Mapper,
46+
request_config,
47+
)
4548
from starlette.datastructures import Headers
4649
from starlette.routing import (
4750
Match,
@@ -307,7 +310,7 @@ def get_current_history_from_session(galaxy_session: Optional[model.GalaxySessio
307310
return None
308311

309312

310-
def fix_url_for(mapper, galaxy_request: GalaxyASGIRequest):
313+
def fix_url_for(mapper: Mapper, galaxy_request: GalaxyASGIRequest):
311314
rc = request_config()
312315
environ = galaxy_request.environ
313316
rc.mapper = mapper

0 commit comments

Comments
 (0)