Skip to content

Commit 4d7bea0

Browse files
Auto-update documentation (#19183)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1 parent 7ef0dbd commit 4d7bea0

File tree

5 files changed

+242
-1
lines changed

5 files changed

+242
-1
lines changed

docs/docs.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -869,6 +869,7 @@
869869
"v3/api-ref/python/prefect-cli-deployment",
870870
"v3/api-ref/python/prefect-cli-dev",
871871
"v3/api-ref/python/prefect-cli-events",
872+
"v3/api-ref/python/prefect-cli-experimental",
872873
"v3/api-ref/python/prefect-cli-flow",
873874
"v3/api-ref/python/prefect-cli-flow_run",
874875
"v3/api-ref/python/prefect-cli-flow_runs_watching",
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
---
2+
title: experimental
3+
sidebarTitle: experimental
4+
---
5+
6+
# `prefect.cli.experimental`
7+
8+
9+
10+
Experimental CLI commands.
11+
12+
These commands provide access to experimental features that are subject to change.
13+
14+
15+
## Functions
16+
17+
### `diagnose` <sup><a href="https://github.com/PrefectHQ/prefect/blob/main/src/prefect/cli/experimental.py#L31" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
18+
19+
```python
20+
diagnose()
21+
```
22+
23+
24+
Diagnose the experimental plugin system.
25+
26+
This command provides information about:
27+
- Whether the plugin system is enabled
28+
- What plugins are discoverable via entry points
29+
- Current configuration (timeouts, allow/deny lists)
30+
31+
Note: This runs the plugin discovery but does not execute hooks.
32+
Use safe mode (PREFECT_EXPERIMENTS_PLUGINS_SAFE_MODE=1) to test plugin loading
33+
without executing hooks.
34+

docs/v3/api-ref/python/prefect-settings-models-experiments.mdx

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,43 @@ sidebarTitle: experiments
77

88
## Classes
99

10-
### `ExperimentsSettings` <sup><a href="https://github.com/PrefectHQ/prefect/blob/main/src/prefect/settings/models/experiments.py#L11" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
10+
### `PluginsSettings` <sup><a href="https://github.com/PrefectHQ/prefect/blob/main/src/prefect/settings/models/experiments.py#L13" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
11+
12+
13+
Settings for configuring the experimental plugin system
14+
15+
16+
**Methods:**
17+
18+
#### `ser_model` <sup><a href="https://github.com/PrefectHQ/prefect/blob/main/src/prefect/settings/base.py#L168" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
19+
20+
```python
21+
ser_model(self, handler: SerializerFunctionWrapHandler, info: SerializationInfo) -> Any
22+
```
23+
24+
#### `settings_customise_sources` <sup><a href="https://github.com/PrefectHQ/prefect/blob/main/src/prefect/settings/base.py#L34" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
25+
26+
```python
27+
settings_customise_sources(cls, settings_cls: type[BaseSettings], init_settings: PydanticBaseSettingsSource, env_settings: PydanticBaseSettingsSource, dotenv_settings: PydanticBaseSettingsSource, file_secret_settings: PydanticBaseSettingsSource) -> tuple[PydanticBaseSettingsSource, ...]
28+
```
29+
30+
Define an order for Prefect settings sources.
31+
32+
The order of the returned callables decides the priority of inputs; first item is the highest priority.
33+
34+
See https://docs.pydantic.dev/latest/concepts/pydantic_settings/#customise-settings-sources
35+
36+
37+
#### `to_environment_variables` <sup><a href="https://github.com/PrefectHQ/prefect/blob/main/src/prefect/settings/base.py#L125" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
38+
39+
```python
40+
to_environment_variables(self, exclude_unset: bool = False, include_secrets: bool = True, include_aliases: bool = False) -> dict[str, str]
41+
```
42+
43+
Convert the settings object to a dictionary of environment variables.
44+
45+
46+
### `ExperimentsSettings` <sup><a href="https://github.com/PrefectHQ/prefect/blob/main/src/prefect/settings/models/experiments.py#L59" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
1147

1248

1349
Settings for configuring experimental features

docs/v3/api-ref/settings-ref.mdx

Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -504,6 +504,13 @@ If `True`, warn on usage of experimental features.
504504
**Supported environment variables**:
505505
`PREFECT_EXPERIMENTS_WARN`, `PREFECT_EXPERIMENTAL_WARN`
506506

507+
### `plugins`
508+
Settings for the experimental plugin system
509+
510+
**Type**: [PluginsSettings](#pluginssettings)
511+
512+
**TOML dotted key path**: `experiments.plugins`
513+
507514
---
508515
## FlowsSettings
509516
Settings for controlling flow behavior
@@ -720,6 +727,81 @@ The maximum size in bytes for a single log.
720727
**Supported environment variables**:
721728
`PREFECT_LOGGING_TO_API_WHEN_MISSING_FLOW`
722729

730+
---
731+
## PluginsSettings
732+
Settings for configuring the experimental plugin system
733+
### `enabled`
734+
Enable the experimental plugin system.
735+
736+
**Type**: `boolean`
737+
738+
**Default**: `False`
739+
740+
**TOML dotted key path**: `experiments.plugins.enabled`
741+
742+
**Supported environment variables**:
743+
`PREFECT_EXPERIMENTS_PLUGINS_ENABLED`
744+
745+
### `allow`
746+
Comma-separated list of plugin names to allow. If set, only these plugins will be loaded.
747+
748+
**Type**: `array | None`
749+
750+
**Default**: `None`
751+
752+
**TOML dotted key path**: `experiments.plugins.allow`
753+
754+
**Supported environment variables**:
755+
`PREFECT_EXPERIMENTS_PLUGINS_ALLOW`
756+
757+
### `deny`
758+
Comma-separated list of plugin names to deny. These plugins will not be loaded.
759+
760+
**Type**: `array | None`
761+
762+
**Default**: `None`
763+
764+
**TOML dotted key path**: `experiments.plugins.deny`
765+
766+
**Supported environment variables**:
767+
`PREFECT_EXPERIMENTS_PLUGINS_DENY`
768+
769+
### `setup_timeout_seconds`
770+
Maximum time in seconds for all plugins to complete their setup hooks.
771+
772+
**Type**: `number`
773+
774+
**Default**: `20.0`
775+
776+
**TOML dotted key path**: `experiments.plugins.setup_timeout_seconds`
777+
778+
**Supported environment variables**:
779+
`PREFECT_EXPERIMENTS_PLUGINS_SETUP_TIMEOUT_SECONDS`
780+
781+
### `strict`
782+
If True, exit if a required plugin fails during setup.
783+
784+
**Type**: `boolean`
785+
786+
**Default**: `False`
787+
788+
**TOML dotted key path**: `experiments.plugins.strict`
789+
790+
**Supported environment variables**:
791+
`PREFECT_EXPERIMENTS_PLUGINS_STRICT`
792+
793+
### `safe_mode`
794+
If True, load plugins but do not execute their hooks. Useful for testing.
795+
796+
**Type**: `boolean`
797+
798+
**Default**: `False`
799+
800+
**TOML dotted key path**: `experiments.plugins.safe_mode`
801+
802+
**Supported environment variables**:
803+
`PREFECT_EXPERIMENTS_PLUGINS_SAFE_MODE`
804+
723805
---
724806
## ResultsSettings
725807
Settings for controlling result storage behavior

schemas/settings.schema.json

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -364,6 +364,11 @@
364364
],
365365
"title": "Warn",
366366
"type": "boolean"
367+
},
368+
"plugins": {
369+
"$ref": "#/$defs/PluginsSettings",
370+
"description": "Settings for the experimental plugin system",
371+
"supported_environment_variables": []
367372
}
368373
},
369374
"title": "ExperimentsSettings",
@@ -576,6 +581,89 @@
576581
"title": "LoggingToAPISettings",
577582
"type": "object"
578583
},
584+
"PluginsSettings": {
585+
"description": "Settings for configuring the experimental plugin system",
586+
"properties": {
587+
"enabled": {
588+
"default": false,
589+
"description": "Enable the experimental plugin system.",
590+
"supported_environment_variables": [
591+
"PREFECT_EXPERIMENTS_PLUGINS_ENABLED"
592+
],
593+
"title": "Enabled",
594+
"type": "boolean"
595+
},
596+
"allow": {
597+
"anyOf": [
598+
{
599+
"items": {
600+
"type": "string"
601+
},
602+
"type": "array",
603+
"uniqueItems": true
604+
},
605+
{
606+
"type": "null"
607+
}
608+
],
609+
"default": null,
610+
"description": "Comma-separated list of plugin names to allow. If set, only these plugins will be loaded.",
611+
"supported_environment_variables": [
612+
"PREFECT_EXPERIMENTS_PLUGINS_ALLOW"
613+
],
614+
"title": "Allow"
615+
},
616+
"deny": {
617+
"anyOf": [
618+
{
619+
"items": {
620+
"type": "string"
621+
},
622+
"type": "array",
623+
"uniqueItems": true
624+
},
625+
{
626+
"type": "null"
627+
}
628+
],
629+
"default": null,
630+
"description": "Comma-separated list of plugin names to deny. These plugins will not be loaded.",
631+
"supported_environment_variables": [
632+
"PREFECT_EXPERIMENTS_PLUGINS_DENY"
633+
],
634+
"title": "Deny"
635+
},
636+
"setup_timeout_seconds": {
637+
"default": 20.0,
638+
"description": "Maximum time in seconds for all plugins to complete their setup hooks.",
639+
"supported_environment_variables": [
640+
"PREFECT_EXPERIMENTS_PLUGINS_SETUP_TIMEOUT_SECONDS"
641+
],
642+
"title": "Setup Timeout Seconds",
643+
"type": "number"
644+
},
645+
"strict": {
646+
"default": false,
647+
"description": "If True, exit if a required plugin fails during setup.",
648+
"supported_environment_variables": [
649+
"PREFECT_EXPERIMENTS_PLUGINS_STRICT"
650+
],
651+
"title": "Strict",
652+
"type": "boolean"
653+
},
654+
"safe_mode": {
655+
"default": false,
656+
"description": "If True, load plugins but do not execute their hooks. Useful for testing.",
657+
"supported_environment_variables": [
658+
"PREFECT_EXPERIMENTS_PLUGINS_SAFE_MODE"
659+
],
660+
"title": "Safe Mode",
661+
"type": "boolean"
662+
}
663+
},
664+
"title": "PluginsSettings",
665+
"type": "object"
666+
},
579667
"ResultsSettings": {
580668
"description": "Settings for controlling result storage behavior",
581669
"properties": {

0 commit comments

Comments
 (0)