1
1
from __future__ import annotations
2
2
3
+ from pathlib import Path
3
4
from typing import (
4
5
TypeVar ,
5
6
Generic ,
@@ -136,8 +137,8 @@ class ConfigurationOption(Provider):
136
137
def as_float (self ) -> TypedConfigurationOption [float ]: ...
137
138
def as_ (self , callback : _Callable [..., T ], * args : Injection , ** kwargs : Injection ) -> TypedConfigurationOption [T ]: ...
138
139
def update (self , value : Any ) -> None : ...
139
- def from_ini (self , filepath : str ) -> None : ...
140
- def from_yaml (self , filepath : str ) -> None : ...
140
+ def from_ini (self , filepath : Union [ Path , str ] ) -> None : ...
141
+ def from_yaml (self , filepath : Union [ Path , str ] ) -> None : ...
141
142
def from_dict (self , options : Dict [str , Any ]) -> None : ...
142
143
def from_env (self , name : str , default : Optional [Any ] = None ) -> None : ...
143
144
@@ -157,8 +158,8 @@ class Configuration(Object):
157
158
def set (self , selector : str , value : Any ) -> OverridingContext : ...
158
159
def reset_cache (self ) -> None : ...
159
160
def update (self , value : Any ) -> None : ...
160
- def from_ini (self , filepath : str ) -> None : ...
161
- def from_yaml (self , filepath : str ) -> None : ...
161
+ def from_ini (self , filepath : Union [ Path , str ] ) -> None : ...
162
+ def from_yaml (self , filepath : Union [ Path , str ] ) -> None : ...
162
163
def from_dict (self , options : Dict [str , Any ]) -> None : ...
163
164
def from_env (self , name : str , default : Optional [Any ] = None ) -> None : ...
164
165
0 commit comments