Attention

This is the documentation for HARP Proxy, actually published as an early preview. Both the software and documentation are a work in progress, and although we already use it on various production servers, they may contain inaccuracies, typographical errors, huge mistakes and empty pages. We work hard to eradicate all mistakes and implement stuff, but it is a long and tedious process. We appreciate your patience and understanding. Of course, any help will be greatly appreciated.

harp.config.settings

class BaseSetting[source]

Bases: object

BaseSetting()

__init__()
Return type:

None

to_dict(*, secure=True)[source]
class Definition[source]

Bases: Generic[T]

Definition(*, path: str, name: str, args: Optional[Tuple] = None, kwargs: Optional[Mapping] = None)

__init__(*, path, name, args=None, kwargs=None)
Parameters:
Return type:

None

build(*args, **kwargs)[source]
Return type:

T

to_dict(*, secure=True)
validate()[source]
args: Tuple | None = None
property factory
kwargs: Mapping | None = None
property module
name: str
path: str
property spec
class DisableableBaseSettings[source]

Bases: BaseSetting

DisableableBaseSettings(**kwargs)

__init__(enabled=True)
Parameters:

enabled (bool | None)

Return type:

None

static __new__(cls, **kwargs)[source]
enabled: bool | None = True
class DisabledSettings[source]

Bases: BaseSetting

DisabledSettings(*args, **kwargs)

__init__(*args, **kwargs)[source]
enabled: bool = False
class FromFileSetting[source]

Bases: BaseSetting

FromFileSetting(from_file: str)

__init__(from_file)
Parameters:

from_file (str)

Return type:

None

exists()[source]
classmethod may_override(instance, attr)[source]
open(*args, **kwargs)[source]
from_file: str
Lazy(path_or_factory, *args, _default=None, **kwargs)[source]
Return type:

Definition[type]

asdict(obj, /, *, secure=True)[source]
settings_dataclass(cls=None, /, *, init=True, repr=True, eq=True, order=False, unsafe_hash=False, frozen=False, match_args=True, kw_only=False, slots=False, weakref_slot=False)

Add dunder methods based on the fields defined in the class.

Examines PEP 526 __annotations__ to determine fields.

If init is true, an __init__() method is added to the class. If repr is true, a __repr__() method is added. If order is true, rich comparison dunder methods are added. If unsafe_hash is true, a __hash__() method is added. If frozen is true, fields may not be assigned to after instance creation. If match_args is true, the __match_args__ tuple is added. If kw_only is true, then by default all fields are keyword-only. If slots is true, a new class with a __slots__ attribute is returned.

Submodules