tabsdatak.conn.common.types
AwsAccessSecretKey | AWS access key ID / secret access key credentials. |
AwsRegionSpec | A valid AWS region name, e.g. |
AzContainerSpec | A valid Azure Blob container name: 3-63 characters, lowercase letters and digits with single (non-leading, non-trailing) hyphens. |
AzureAccountKey | Azure storage account name / key credentials. |
AzureCredentials | Abstract base for Azure credential types. |
BoolSpec | A boolean flag as text: one of true/false, t/f, yes/no, y/n, on/off, 1/0 (case-insensitive). |
CfgSpec | Type for a connector conn_cfg field: a free-form dict forwarding 3rd-party-specific configuration. |
cloud_full_path | Join a cloud base_path (object-key prefix) with path, stripping leading and trailing / from each side and from the result. |
CloudRelativePathSpec | A cloud object-key prefix, relative to the container/bucket root. |
Credentials | Abstract base for every credential type. |
DataType | Placeholder enumeration of basic data types. |
EntityWhitelistSpec | Optional list of regex patterns narrowing which of the external system's entities (tables / collections / objects / datasets / ...) a source considers. |
GCPCredentials | Abstract base for Google Cloud credential types. |
GCPHmac | HMAC access key / secret for GCS's S3-compatible endpoint. |
GCPJson | GCP service-account JSON key credentials. |
GCSBucketSpec | A valid GCS bucket name: 3-63 characters, lowercase letters, digits, hyphens and underscores, starting and ending with a letter or digit. |
HostSpec | A DNS host name or IPv4 literal (e.g. |
local_full_path | Join a local-filesystem base_path with the relative path, returning a native path for the running OS. |
LocalAbsolutePathSpec | An absolute local-filesystem path: POSIX (/a/b) or Windows drive-absolute (C:/a/b or C:\a\b). |
normalize_dir_path | Render path as a directory-style prefix with a leading and/or trailing / forced on per the flags -- for an external driver that expects a specific spelling of the prefix. |
PortSpec | A TCP port number, 1-65535. |
S3BucketSpec | A valid S3 bucket name: 3-63 characters, lowercase letters, digits and hyphens, starting and ending with a letter or digit. |
UserPassword | Username / password credentials. |
AwsRegionSpec
type_aliasAwsRegionSpec: StrOrSecretSpec
Resolved type:
str | Secret
A valid AWS region name, e.g. us-east-1 or us-gov-west-1.
Accepts a plain string or a Secret.
AzContainerSpec
type_aliasAzContainerSpec: StrOrSecretSpec
Resolved type:
str | Secret
A valid Azure Blob container name: 3-63 characters, lowercase
letters and digits with single (non-leading, non-trailing) hyphens.
Accepts a plain string or a Secret.
BoolSpec
type_aliasBoolSpec: StrOrSecretSpec
Resolved type:
str | Secret
A boolean flag as text: one of true/false, t/f,
yes/no, y/n, on/off, 1/0
(case-insensitive). Accepts a plain string or a Secret; read the
parsed bool with _convert(x, bool).
CfgSpec
type_aliasCfgSpec: dict
Type for a connector conn_cfg field: a free-form dict forwarding
3rd-party-specific configuration.
Keys targeting a dependency are prefixed with its package name plus
. (e.g. "sqlalchemy.connect_args", "mysql.charset"); the
connector strips the prefix before forwarding. Values must be
JSON-like: str / int / float / bool / None, or a
(recursively validated) str-keyed dict or list.
cloud_full_path
functiondef cloud_full_path(base_path: CloudRelativePathSpec, path: str) -> str
Join a cloud base_path (object-key prefix) with path, stripping
leading and trailing / from each side and from the result.
base_path may be a str or a Secret whose .value() resolves to
the path string.
Parameters:
base_pathCloudRelativePathSpec (str | Secret)pathstrCloudRelativePathSpec
type_aliasCloudRelativePathSpec: StrOrSecretSpec
Resolved type:
str | Secret
A cloud object-key prefix, relative to the container/bucket root.
Starts with /, has no trailing / (except the bare root /) and no
empty segments (no //); backslash and NUL are forbidden. Accepts a
plain string or a Secret.
DataType
classclass DataType(
BOOL = 'bool',
INT = 'int',
FLOAT = 'float',
STRING = 'string',
BYTES = 'bytes',
DATE = 'date',
TIME = 'time',
DATETIME = 'datetime',
)
Bases: Enum
Placeholder enumeration of basic data types.
Not yet part of the stable public surface; subject to change.
Parameters:
BOOLINTFLOATSTRINGBYTESDATETIMEDATETIMEEntityWhitelistSpec
type_aliasEntityWhitelistSpec: list[str]
Optional list of regex patterns narrowing which of the external system's entities (tables / collections / objects / datasets / ...) a source considers.
None (the default) means no filtering. Each entry must be a valid
Python regular expression, matched against entity metadata names.
GCSBucketSpec
type_aliasGCSBucketSpec: StrOrSecretSpec
Resolved type:
str | Secret
A valid GCS bucket name: 3-63 characters, lowercase letters, digits,
hyphens and underscores, starting and ending with a letter or digit.
Accepts a plain string or a Secret.
HostSpec
type_aliasHostSpec: StrOrSecretSpec
Resolved type:
str | Secret
A DNS host name or IPv4 literal (e.g. localhost,
db.example.com, 10.0.0.1). Accepts a plain string or a
Secret.
local_full_path
functiondef local_full_path(base_path: LocalAbsolutePathSpec, path: str) -> str
Join a local-filesystem base_path with the relative path,
returning a native path for the running OS.
base_path is absolute (POSIX or Windows drive-absolute). path is
relative to it and may use / or \ separators; both are accepted
and the segments are re-joined with the OS-native separator so the
result is usable directly for filesystem access. base_path may be a
str or a Secret.
Parameters:
base_pathLocalAbsolutePathSpec (str | Secret)pathstrLocalAbsolutePathSpec
type_aliasLocalAbsolutePathSpec: StrOrSecretSpec
Resolved type:
str | Secret
An absolute local-filesystem path: POSIX (/a/b) or Windows
drive-absolute (C:/a/b or C:\a\b). UNC and relative paths are
rejected; no empty segments or NUL. Accepts a plain string or a Secret.
normalize_dir_path
functiondef normalize_dir_path(path: str, lead_separator: bool, back_separator: bool) -> str
Render path as a directory-style prefix with a leading and/or
trailing / forced on per the flags -- for an external driver that
expects a specific spelling of the prefix. path is first reduced
to its slash-stripped core; an empty core yields "" regardless of
the flags (there is no directory to delimit).
Parameters:
pathstrlead_separatorboolback_separatorboolPortSpec
type_aliasPortSpec: StrOrSecretSpec
Resolved type:
str | Secret
A TCP port number, 1-65535. Accepts a plain string or a Secret;
read the parsed int with _convert(x, int).
S3BucketSpec
type_aliasS3BucketSpec: StrOrSecretSpec
Resolved type:
str | Secret
A valid S3 bucket name: 3-63 characters, lowercase letters, digits
and hyphens, starting and ending with a letter or digit. Accepts a
plain string or a Secret.