# Configuration


Utilities for interacting with Prefect configuration. These are only intended to be used for testing.

# Functions

top-level functions:                                                                                                                                                       

prefect.utilities.configuration.set_temporary_config

(temp_config)[source]

Temporarily sets configuration values for the duration of the context manager.

This is only intended to be used for testing.

Args:

  • temp_config (dict): a dictionary containing (possibly nested) configuration keys and values. Nested configuration keys should be supplied as .-delimited strings.
Example:
    with set_temporary_config({'setting': 1, 'nested.setting': 2}):
assert prefect.config.setting == 1
assert prefect.config.nested.setting == 2


This documentation was auto-generated from commit bd9182e
on July 31, 2024 at 18:02 UTC