Skip to main content

fused.options

options

List global configuration options.

This object contains a set of configuration options that control global behavior of the library. This object can be used to modify the options.

Examples:

Change the request_timeout option from its default value to 60 seconds:

fused.options.request_timeout = 60

Options

auth

auth: AuthOptions = Field(default_factory=AuthOptions)

Options for authentication.


base_url

base_url: str = PROD_DEFAULT_BASE_URL

Fused API endpoint


base_web_url

base_web_url

Base URL for web interface.


cache_decorator_max_age

cache_decorator_max_age: int = 60 * 60 * 48  # 48 hours

Default max age for cache decorated functions. Accepts duration strings like "12h", "30m", "7d", or integer seconds.


cache_directory

cache_directory: Path | None = None

The base directory for storing cached results.


cache_storage

cache_storage: StorageStr = 'auto'

Specify the default cache storage type


data_directory

data_directory: Path = None

The base directory for storing data results. Note: if storage type is 'object', then this path is relative to fd_prefix.


default_dtype_out_raster

default_dtype_out_raster: StrictStr = 'npy,tiff'

Default transfer type for raster data


default_dtype_out_simple

default_dtype_out_simple: StrictStr = 'json'

Default transfer type for simple Python data (bool, int, float, str, list)


default_dtype_out_vector

default_dtype_out_vector: StrictStr = 'parquet'

Default transfer type for vector (tabular) data


default_run_headers

default_run_headers: Optional[Dict[str, str]] = {
"X-Fused-Cache-Disable": "true"
}

(Advanced) Default headers to include with UDF run requests.


default_send_status_email

default_send_status_email: StrictBool = True

Whether to send a status email to the user when a job is complete.


default_udf_run_engine

default_udf_run_engine: Optional[StrictStr] = None

Default engine to run UDFs, one of: "local" or "remote".


default_validate_imports

default_validate_imports: StrictBool = False

Default for whether to validate imports in UDFs before run_local, run_batch.


fd_prefix

fd_prefix: Optional[str] = None

If set, where fd:// scheme URLs will resolve to. By default will infer this from your user account.


gcp_project_name

gcp_project_name: Optional[StrictStr] = None

Project name for GCS to use for GCS operations.


gcs_filename

gcs_filename: str = '/tmp/.gcs.fused'

Filename for saving temporary GCS credentials to locally or in rt2 instance


gcs_secret

gcs_secret: str = 'gcs_fused'

Secret name for GCS credentials.


job_id

job_id: Optional[StrictStr] = None

ID of the job being executed (set by job2 when running in job context). This is automatically populated when running inside a Fused batch job.


local_engine_cache

local_engine_cache: StrictBool = True

Enable UDF cache with local engine


logging

logging: StrictBool = Field(default=False, validate_default=True)

Control logging for Fused


max_recursion_factor

max_recursion_factor: int = 5

Maximum recursion factor for UDFs. This is used to limit the number of recursive calls to UDFs. If a UDF exceeds this limit, an error will be raised.


max_workers

max_workers: int = 16

Maximum number of threads, when multithreading requests


metadata_request_timeout

metadata_request_timeout: float = 60.0

Request timeout for file metadata requests (e.g., /file-metadata endpoint). These requests may involve processing large parquet files and can take longer.


never_import

never_import: StrictBool = False

Never import UDF code when loading UDFs.


no_login

no_login: StrictBool = False

If set, Fused will not attempt to login automatically when needed.


prompt_to_login

prompt_to_login: StrictBool = False

Automatically prompt the user to login when importing Fused.


pyodide_async_requests

pyodide_async_requests: StrictBool = False

If set, Fused is being called inside Pyodide and should use pyodide for async HTTP requests.


realtime_client_id

realtime_client_id: Optional[StrictStr] = None

Client ID for realtime service.


request_max_retries

request_max_retries: int = 5

Maximum number of retries for API requests


request_retry_base_delay

request_retry_base_delay: float = 1.0

Base delay before retrying a API request in seconds


request_timeout

request_timeout: Union[Tuple[float, float], float, None] = 5

Request timeout for the Fused service

May be set to a tuple of connection timeout and read timeout


row_group_batch_size

row_group_batch_size: int = 32768

Target size in bytes for combining adjacent row group downloads. Adjacent row groups from the same file will be combined into single downloads until this threshold is reached. Default is 32KB (32768 bytes), which is optimized for S3 performance.


run_timeout

run_timeout: float = 130

Request timeout for UDF run requests to the Fused service


save_user_settings

save_user_settings: StrictBool = True

Save per-user settings such as credentials and environment IDs.


shared_udf_base_url

shared_udf_base_url: str = PROD_SHARED_UDF_DEFAULT_BASE_URL

Shared UDF API endpoint


show

show: ShowOptions = Field(default_factory=ShowOptions)

Options for object reprs and how data are shown for debugging.


temp_directory

temp_directory: Path = Path(tempfile.gettempdir())

The base directory for storing temporary files.


use_process_pool_for_local_submit

use_process_pool_for_local_submit: StrictBool = False

Use ProcessPoolExecutor instead of ThreadPoolExecutor for local engine submit. This avoids GDAL thread-safety issues and Python GIL limitations, but has higher memory overhead and slower startup time.


verbose_cached_functions

verbose_cached_functions: StrictBool = True

Whether to print logs from cache decorated functions by default


verbose_udf_runs

verbose_udf_runs: StrictBool = True

Whether to print logs from UDF runs by default


save

save()

Save Fused options to ~/.fused/settings.toml. They will be automatically reloaded the next time fused-py is imported.