1010from .._types import SSLCtx
1111from ..asgi import LifespanProtocol , _callback_wrapper as _asgi_call_wrap
1212from ..errors import ConfigurationError , FatalError
13+ from ..files import StaticFilesSettings
1314from ..rsgi import _callback_wrapper as _rsgi_call_wrap , _callbacks_from_target as _rsgi_cbs_from_target
1415from ..wsgi import _callback_wrapper as _wsgi_call_wrap
1516from .common import (
@@ -88,7 +89,7 @@ def _spawn_asgi_worker(
8889 http1_settings : HTTP1Settings | None ,
8990 http2_settings : HTTP2Settings | None ,
9091 websockets : bool ,
91- static_path : tuple [ str , str , str | None ] | None ,
92+ static_files : StaticFilesSettings | None ,
9293 log_access_fmt : str | None ,
9394 ssl_ctx : SSLCtx ,
9495 scope_opts : dict [str , Any ],
@@ -107,7 +108,7 @@ def _spawn_asgi_worker(
107108 http1_settings ,
108109 http2_settings ,
109110 websockets ,
110- static_path ,
111+ static_files ,
111112 * ssl_ctx ,
112113 )
113114 serve = getattr (worker , WORKERS_METHODS [runtime_mode ][sock .is_uds ()])
@@ -133,7 +134,7 @@ def _spawn_asgi_lifespan_worker(
133134 http1_settings : HTTP1Settings | None ,
134135 http2_settings : HTTP2Settings | None ,
135136 websockets : bool ,
136- static_path : tuple [ str , str , str | None ] | None ,
137+ static_files : StaticFilesSettings | None ,
137138 log_access_fmt : str | None ,
138139 ssl_ctx : SSLCtx ,
139140 scope_opts : dict [str , Any ],
@@ -160,7 +161,7 @@ def _spawn_asgi_lifespan_worker(
160161 http1_settings ,
161162 http2_settings ,
162163 websockets ,
163- static_path ,
164+ static_files ,
164165 * ssl_ctx ,
165166 )
166167 serve = getattr (worker , WORKERS_METHODS [runtime_mode ][sock .is_uds ()])
@@ -187,7 +188,7 @@ def _spawn_rsgi_worker(
187188 http1_settings : HTTP1Settings | None ,
188189 http2_settings : HTTP2Settings | None ,
189190 websockets : bool ,
190- static_path : tuple [ str , str , str | None ] | None ,
191+ static_files : StaticFilesSettings | None ,
191192 log_access_fmt : str | None ,
192193 ssl_ctx : SSLCtx ,
193194 scope_opts : dict [str , Any ],
@@ -208,7 +209,7 @@ def _spawn_rsgi_worker(
208209 http1_settings ,
209210 http2_settings ,
210211 websockets ,
211- static_path ,
212+ static_files ,
212213 * ssl_ctx ,
213214 )
214215 serve = getattr (worker , WORKERS_METHODS [runtime_mode ][sock .is_uds ()])
@@ -235,7 +236,7 @@ def _spawn_wsgi_worker(
235236 http1_settings : HTTP1Settings | None ,
236237 http2_settings : HTTP2Settings | None ,
237238 websockets : bool ,
238- static_path : tuple [ str , str , str | None ] | None ,
239+ static_files : StaticFilesSettings | None ,
239240 log_access_fmt : str | None ,
240241 ssl_ctx : SSLCtx ,
241242 scope_opts : dict [str , Any ],
@@ -253,7 +254,7 @@ def _spawn_wsgi_worker(
253254 http_mode ,
254255 http1_settings ,
255256 http2_settings ,
256- static_path ,
257+ static_files ,
257258 * ssl_ctx ,
258259 )
259260 serve = getattr (worker , WORKERS_METHODS [runtime_mode ][sock .is_uds ()])
@@ -284,7 +285,7 @@ def _spawn_worker(self, idx, target, callback_loader) -> WorkerThread:
284285 self .http1_settings ,
285286 self .http2_settings ,
286287 self .websockets ,
287- self .static_path ,
288+ self .static_files ,
288289 self .log_access_format if self .log_access else None ,
289290 self .ssl_ctx ,
290291 {'url_path_prefix' : self .url_path_prefix },
0 commit comments