Method: flask.blueprints.Blueprint.__init__
Calls: 89, Exceptions: 2, Paths: 3Back
Path 1: 87 calls (0.98)
'bp' (40) 'test' (13) 'parent' (8) 'child' (8) 'frontend' (2) 'blue' (2) 'foo' (1) 'backend' (1) 'sideend' (1) 'errors' (1)
'test_blueprints' (70) 'test_async' (8) 'test_cli' (5) 'test_user_error_handler' (2) 'test_basic' (1) 'test_testing' (1)
None (86) 'static' (1)
None (87)
None (86) 'template' (1)
None (70) '/foo/' (4) '' (2) '/' (2) '/foo' (2) '/parent' (2) '/foo//' (1) '/
None (85) 'api' (1) 'xxx' (1)
None (87)
None (87)
object (84) 'customized' (1) None (1) 'blue' (1)
1def __init__(
2 self,
3 name: str,
4 import_name: str,
5 static_folder: str | os.PathLike | None = None,
6 static_url_path: str | None = None,
7 template_folder: str | os.PathLike | None = None,
8 url_prefix: str | None = None,
9 subdomain: str | None = None,
10 url_defaults: dict | None = None,
11 root_path: str | None = None,
12 cli_group: str | None = _sentinel, # type: ignore
13 ):
14 super().__init__(
15 import_name=import_name,
16 static_folder=static_folder,
17 static_url_path=static_url_path,
18 template_folder=template_folder,
19 root_path=root_path,
20 )
21
22 if not name:
23 raise ValueError("'name' may not be empty.")
24
25 if "." in name:
26 raise ValueError("'name' may not contain a dot '.' character.")
27
28 self.name = name
29 self.url_prefix = url_prefix
30 self.subdomain = subdomain
31 self.deferred_functions: list[DeferredSetupFunction] = []
32
33 if url_defaults is None:
34 url_defaults = {}
35
36 self.url_values_defaults = url_defaults
37 self.cli_group = cli_group
38 self._blueprints: list[tuple[Blueprint, dict]] = []
Path 2: 1 calls (0.01)
'app.ui' (1)
'test_blueprints' (1)
None (1)
None (1)
None (1)
None (1)
None (1)
None (1)
None (1)
object (1)
ValueError (1)
1def __init__(
2 self,
3 name: str,
4 import_name: str,
5 static_folder: str | os.PathLike | None = None,
6 static_url_path: str | None = None,
7 template_folder: str | os.PathLike | None = None,
8 url_prefix: str | None = None,
9 subdomain: str | None = None,
10 url_defaults: dict | None = None,
11 root_path: str | None = None,
12 cli_group: str | None = _sentinel, # type: ignore
13 ):
14 super().__init__(
15 import_name=import_name,
16 static_folder=static_folder,
17 static_url_path=static_url_path,
18 template_folder=template_folder,
19 root_path=root_path,
20 )
21
22 if not name:
23 raise ValueError("'name' may not be empty.")
24
25 if "." in name:
26 raise ValueError("'name' may not contain a dot '.' character.")
27
28 self.name = name
29 self.url_prefix = url_prefix
30 self.subdomain = subdomain
31 self.deferred_functions: list[DeferredSetupFunction] = []
32
33 if url_defaults is None:
34 url_defaults = {}
35
36 self.url_values_defaults = url_defaults
37 self.cli_group = cli_group
38 self._blueprints: list[tuple[Blueprint, dict]] = []
Path 3: 1 calls (0.01)
'' (1)
'test_blueprints' (1)
None (1)
None (1)
None (1)
None (1)
None (1)
None (1)
None (1)
object (1)
ValueError (1)
1def __init__(
2 self,
3 name: str,
4 import_name: str,
5 static_folder: str | os.PathLike | None = None,
6 static_url_path: str | None = None,
7 template_folder: str | os.PathLike | None = None,
8 url_prefix: str | None = None,
9 subdomain: str | None = None,
10 url_defaults: dict | None = None,
11 root_path: str | None = None,
12 cli_group: str | None = _sentinel, # type: ignore
13 ):
14 super().__init__(
15 import_name=import_name,
16 static_folder=static_folder,
17 static_url_path=static_url_path,
18 template_folder=template_folder,
19 root_path=root_path,
20 )
21
22 if not name:
23 raise ValueError("'name' may not be empty.")
24
25 if "." in name:
26 raise ValueError("'name' may not contain a dot '.' character.")
27
28 self.name = name
29 self.url_prefix = url_prefix
30 self.subdomain = subdomain
31 self.deferred_functions: list[DeferredSetupFunction] = []
32
33 if url_defaults is None:
34 url_defaults = {}
35
36 self.url_values_defaults = url_defaults
37 self.cli_group = cli_group
38 self._blueprints: list[tuple[Blueprint, dict]] = []