Skip to content

Commit 1e2072a

Browse files
authored
Merge branch 'dagster-io:master' into fix/celery-crash-detection
2 parents 1c4fa8d + fbee33e commit 1e2072a

418 files changed

Lines changed: 16265 additions & 11817 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.buildkite/dagster-buildkite/dagster_buildkite/steps/dagster.py

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ def build_repo_wide_steps(ctx: BuildkiteContext) -> list[StepConfiguration]:
3232
# Other linters may be run in per-package environments because they rely on the dependencies of
3333
# the target. `pyright` and `ruff` are run for the whole repo at once.
3434
return [
35-
*build_check_changelog_steps(ctx),
3635
*build_repo_wide_pyright_steps(ctx),
3736
*build_repo_wide_ruff_steps(ctx),
3837
*build_repo_wide_prettier_steps(ctx),
@@ -91,18 +90,6 @@ def build_repo_wide_prettier_steps(ctx: BuildkiteContext) -> list[CommandStepCon
9190
]
9291

9392

94-
def build_check_changelog_steps(ctx: BuildkiteContext) -> list[CommandStepConfiguration]:
95-
skip_reason = _get_check_changelog_step_skip_reason(ctx)
96-
cmd = (
97-
f"python {oss_path('scripts/check_changelog.py')} {ctx.release_version}"
98-
if not skip_reason
99-
else "echo skipped"
100-
)
101-
return [
102-
CommandStepBuilder(":memo: changelog").run(cmd).on_test_image().skip(skip_reason).build(),
103-
]
104-
105-
10693
def build_repo_wide_pyright_steps(ctx: BuildkiteContext) -> list[StepConfiguration]:
10794
return [
10895
GroupStepBuilder(
@@ -223,9 +210,3 @@ def _get_prettier_step_skip_reason(ctx: BuildkiteContext) -> str | None:
223210
elif ctx.has_non_docs_markdown_changes():
224211
return None
225212
return "No yaml changes or markdown changes outside docs"
226-
227-
228-
def _get_check_changelog_step_skip_reason(ctx: BuildkiteContext) -> str | None:
229-
if not ctx.is_release_branch:
230-
return "Not a release branch"
231-
return None

.buildkite/dagster-buildkite/dagster_buildkite/steps/docs.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ def build_build_docs_step(ctx: BuildkiteContext) -> GroupLeafStepConfiguration:
3535
f'pip install -U "{UV_PIN}"',
3636
"yarn install",
3737
"yarn test",
38+
"yarn lint-check",
3839
"yarn build-api-docs",
3940
"yarn build",
4041
)

.buildkite/dagster-buildkite/dagster_buildkite/steps/packages.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -506,6 +506,12 @@ def _example_packages_with_custom_config(ctx: BuildkiteContext) -> list[PackageS
506506
AvailablePythonVersion.V3_14, # duckdb
507507
],
508508
),
509+
PackageSpec(
510+
oss_path("examples/project_multi_tenant"),
511+
unsupported_python_versions=[
512+
AvailablePythonVersion.V3_10, # requires-python >= 3.11
513+
],
514+
),
509515
PackageSpec(
510516
oss_path("examples/with_great_expectations"),
511517
unsupported_python_versions=[
@@ -835,12 +841,6 @@ def _library_packages_with_custom_config(ctx: BuildkiteContext) -> list[PackageS
835841
)
836842
),
837843
),
838-
PackageSpec(
839-
oss_path("python_modules/libraries/dagster-dg-cli"),
840-
name="dagster-dg-cli-mcp",
841-
pytest_tox_factors=[ToxFactor("mcp")],
842-
force_run_fn=BuildkiteContext.has_dg_or_component_integration_changes,
843-
),
844844
PackageSpec(
845845
oss_path("python_modules/libraries/dagster-aws"),
846846
env_vars=["AWS_DEFAULT_REGION", "AWS_ACCESS_KEY_ID", "AWS_SECRET_ACCESS_KEY"],
Lines changed: 109 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,109 @@
1+
# Copybara Sync Gate (OSS)
2+
#
3+
# Prevents merging OSS PRs while unsynced internal→OSS changes exist.
4+
# Without this gate, the Copybara OSS→internal sync of this commit would
5+
# overwrite those internal changes, silently reverting them.
6+
#
7+
# Required status check: the job name "copybara-sync-gate".
8+
#
9+
# Works with GitHub merge queue: the pull_request trigger provides a
10+
# passthrough (instant success) so the PR can enter the merge queue. The
11+
# real check runs on the merge_group trigger at merge time, polling for
12+
# up to 10 minutes if the sync is behind.
13+
#
14+
# Prerequisites:
15+
# - Repository secret ELEMENTL_DEVTOOLS_PAT: a GitHub PAT with read
16+
# access to dagster-io/internal (needed to check internal commit history).
17+
18+
name: Copybara Sync Gate
19+
20+
on:
21+
pull_request:
22+
types: [opened, synchronize, reopened]
23+
merge_group:
24+
25+
permissions:
26+
contents: read
27+
28+
jobs:
29+
copybara-sync-gate:
30+
runs-on: ubuntu-latest
31+
steps:
32+
- name: Wait for internal-to-OSS sync to catch up
33+
if: github.event_name == 'merge_group'
34+
env:
35+
GH_TOKEN: ${{ secrets.ELEMENTL_DEVTOOLS_PAT }}
36+
run: |
37+
set -euo pipefail
38+
39+
check_sync() {
40+
# Find the last internal commit that was synced to OSS.
41+
# Copybara labels synced commits with "Internal-RevId: <internal-hash>".
42+
LAST_SYNCED=$(gh api "repos/${{ github.repository }}/commits" \
43+
--method GET -f sha=master -f per_page=100 \
44+
--jq 'map(select(.commit.message | test("Internal-RevId:"))) | .[0].commit.message' \
45+
| grep -oP 'Internal-RevId: \K[a-f0-9]+')
46+
47+
if [ -z "$LAST_SYNCED" ]; then
48+
echo "Could not find any Internal-RevId in the last 100 OSS commits"
49+
return 1
50+
fi
51+
52+
# Check how many internal commits are ahead of the last synced one.
53+
COMPARE=$(gh api "repos/dagster-io/internal/compare/${LAST_SYNCED}...master")
54+
AHEAD=$(echo "$COMPARE" | jq '.ahead_by')
55+
56+
if [ "$AHEAD" -eq 0 ]; then
57+
echo "Internal-to-OSS sync is caught up"
58+
return 0
59+
fi
60+
61+
# Filter out commits that originated from OSS (noops for this direction).
62+
# Then check if any remaining commits touch dagster-oss/.
63+
UNSYNCED_SHAS=$(echo "$COMPARE" | jq -r \
64+
'[.commits[] | select(.commit.message | test("Dagster-RevId:") | not)] | .[].sha')
65+
66+
if [ -z "$UNSYNCED_SHAS" ]; then
67+
echo "All $AHEAD ahead commits originated from OSS — sync is effectively caught up"
68+
return 0
69+
fi
70+
71+
# Check if any unsynced commits touch dagster-oss/.
72+
BLOCKING=0
73+
for SHA in $UNSYNCED_SHAS; do
74+
TOUCHES_OSS=$(gh api "repos/dagster-io/internal/commits/$SHA" \
75+
--jq '[.files[].filename | select(startswith("dagster-oss/"))] | length')
76+
if [ "$TOUCHES_OSS" -gt 0 ]; then
77+
BLOCKING=$((BLOCKING + 1))
78+
fi
79+
done
80+
81+
if [ "$BLOCKING" -eq 0 ]; then
82+
echo "No unsynced internal commits touch dagster-oss/ — safe to merge"
83+
return 0
84+
fi
85+
86+
echo "$BLOCKING unsynced internal commit(s) touch dagster-oss/"
87+
return 1
88+
}
89+
90+
MAX_ATTEMPTS=30 # 10 minutes at 20s intervals
91+
for i in $(seq 1 $MAX_ATTEMPTS); do
92+
if check_sync; then
93+
echo "Sync gate passed"
94+
exit 0
95+
fi
96+
97+
if [ "$i" -eq 1 ]; then
98+
echo "Waiting for copybara internal-to-public sync to complete..."
99+
fi
100+
101+
if [ "$i" -eq "$MAX_ATTEMPTS" ]; then
102+
echo "::error::Internal-to-OSS sync did not catch up within 10 minutes."
103+
echo "::error::Merging this PR risks having internal changes silently reverted."
104+
echo "::error::Check the 'copybara: internal to public' Buildkite pipeline."
105+
exit 1
106+
fi
107+
108+
sleep 20
109+
done

CHANGES.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,39 @@
11
# Changelog
22

3+
## 1.12.22 (core) / 0.28.22 (libraries)
4+
5+
### New
6+
7+
- [dg] `dg` projects can now configure `agent_queue` and `image` in `pyproject.toml` under `[tool.dg.project]`, which are included in the generated `dagster_cloud.yaml` when running `dg plus deploy`.
8+
- [dg] Added `dg api job list` and `dg api job get` commands for querying job metadata including schedules, sensors, and tags.
9+
- [dg] Added `dg api asset-check list`, `dg api asset-check get-executions`, and `dg api asset get-partition-status` commands.
10+
- [ui] The asset overview page now shows a loading spinner for "Latest materialization" while data is loading, instead of a dash.
11+
- [ui] Removed the legacy asset catalog component and the `flagAssetCatalogSidebar` feature flag. The asset catalog sidebar is now always enabled.
12+
- [ui] The pipeline snapshot link is no longer shown in the Run Actions Menu for hidden asset group jobs.
13+
- [dagster-aws] The `EcsRunLauncher` and Dagster+ ECS agent now supply idempotency tokens when creating ECS services and tasks, improving retry behavior after transient failures.
14+
- [dagster-dbt] `DbtCloudComponent` now supports an option to include a polling sensor for monitoring dbt Cloud job runs.
15+
16+
### Bugfixes
17+
18+
- Fixed `snap_to_yaml` incorrectly removing empty dicts that represent valid config values for `Permissive`, `Map`, and `Noneable` config types.
19+
- Fixed an issue where resources defined in parent components could incorrectly trigger `DagsterInvalidDefinitionError` during nested component `post_processing` resolution. (Thanks, [@vidiyala99](https://github.com/vidiyala99)!)
20+
- [dagster-aws] Fixed `PipesECSClient` incorrectly treating a task that failed to start as a successful execution.
21+
- [dagster-fivetran] Fixed an incorrect connector URL format generated by the Fivetran integration.
22+
- [ui] Fixed a performance issue where canceling a backfill before any runs executed would unnecessarily fetch the entire asset materialization history.
23+
- [dg] Fixed `dg plus deploy` not correctly pulling in environment variables when refreshing definitions state for state-backed components.
24+
- [ui] Fixed ANSI color rendering in run logs.
25+
- [ui] Fixed a visual rendering issue with the graph depth input field.
26+
27+
### Documentation
28+
29+
- Added a migration guide for moving from sensors to declarative automation.
30+
- Added documentation for the ECS executor.
31+
32+
### Dagster Plus
33+
34+
- Alert policies can now be muted for a configurable duration. Muted policies do not send notifications and show when they will resume.
35+
- [dagster-dbt] Added `dg plus integrations dbt download-manifest` command to download dbt manifests from Dagster Plus for local development.
36+
337
## 1.12.21 (core) / 0.28.21 (libraries)
438

539
### New

docs/docs/about/contributing-docs/formatting-style.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,10 @@ Available admonitions:
4747
- `:::warning`
4848
- `:::danger`
4949

50+
Always include a blank line after the admonition label and before the closing set of colons.
51+
52+
### Admonition titles
53+
5054
You can specify an optional title (with Markdown syntax) for admonitions (note that you do not need to include brackets -- unclear why Docusaurus is adding them when rendering the code block below, but they are unnecessary in Dagster docs):
5155

5256
```
@@ -506,7 +510,7 @@ The `sidebar_custom_props` values are used to render the doc cards on the integr
506510

507511
- The names of programming languages (`Python`, `Rust`) should follow the official style guidelines for that language.
508512

509-
### **Key terms and definitions**
513+
### Key terms and definitions
510514

511515
| **Term** | **Definition** | **Notes** | **Formatting** |
512516
| ----------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- | -------------- |

docs/docs/deployment/dagster-plus/deploying-code/branch-deployments/multiple-deployments.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,16 @@ locations:
9595
agent_queue: <queue name>
9696
```
9797

98+
For `dg`-based projects, you can alternatively set the agent queue in `pyproject.toml`:
99+
100+
```toml
101+
# pyproject.toml
102+
103+
[tool.dg.project]
104+
root_module = "my_project"
105+
agent_queue = "<queue name>"
106+
```
107+
98108
For more information about agent queue routing or code location configuration, see:
99109

100110
- [Agent queue routing](/deployment/dagster-plus/hybrid/multiple#routing-requests-to-specific-agents)

docs/docs/deployment/dagster-plus/deploying-code/configuring-ci-cd.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,12 @@ Pushing changes to the `main` branch of that project repository will automatical
8686
8787
During the deployment, the agent will attempt to load your code and update the metadata in Dagster+. When that has finished, you should see the GitHub Action complete successfully, and also be able to see the code location under the **Deployment** tag in Dagster+.
8888
89+
:::note Environment variables in CI
90+
91+
During the deployment process, environment variables configured in your Dagster+ deployment are automatically fetched and made available during code loading. This means components that require credentials (such as database passwords or API keys) will have access to them in CI without needing to duplicate them as GitHub Secrets. The appropriate scope is selected automatically based on deployment type (full deployment or branch deployment).
92+
93+
:::
94+
8995
<UpdateGitHubActionVersion />
9096
9197
## GitLab

docs/docs/deployment/dagster-plus/deploying-code/full-deployments/full-deployment-settings-reference.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ sso_default_role: EDITOR
118118

119119
### Non-isolated runs
120120

121-
Configure [non-isolated runs](/deployment/dagster-plus/serverless/run-isolation) on your deployment.
121+
Configure [non-isolated runs](/deployment/dagster-plus/run-isolation) on your deployment.
122122

123123
```yaml
124124
non_isolated_runs:
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
---
2+
title: Deploying to both Serverless and Hybrid code locations
3+
description: Deploy both Dagster+ Serverless and Hybrid code locations from a single repository using agent queues and separate CI/CD workflows.
4+
sidebar_position: 9000
5+
tags: [dagster-plus-feature]
6+
---
7+
8+
Deploy both Dagster+ Serverless and Hybrid code locations from a single repository using agent queues and separate CI/CD workflows.
9+
10+
Serverless code locations require no additional deployment configuration. Hybrid code locations need a `build.yaml` to configure Docker image builds, and `agent_queue` set in [`pyproject.toml`](/api/clis/dg-cli/dg-cli-configuration#project-configuration-file) to route to the correct agent.
11+
12+
## Prerequisites
13+
14+
- A repository containing the code for both Serverless and Hybrid code locations
15+
- An agent configured to serve the Hybrid queue. For details, see [Routing requests to specific agents](/deployment/dagster-plus/hybrid/multiple#routing-requests-to-specific-agents).
16+
17+
:::note
18+
19+
Agent queues are a Dagster+ Pro feature.
20+
21+
:::
22+
23+
## Step 1: Configure the Hybrid code location
24+
25+
Add a `build.yaml` to the directory containing the Hybrid code location. The Hybrid location uses Docker images and routes to a dedicated agent queue.
26+
27+
The `build.registry` field specifies where the Docker image is stored.
28+
29+
```yaml title="build.yaml"
30+
locations:
31+
- location_name: hybrid-location
32+
code_source:
33+
package_name: hybrid_location.definitions
34+
working_directory: ./src/
35+
build:
36+
registry: ghcr.io/my-org/my-repo/hybrid-location
37+
```
38+
39+
Configure `agent_queue` in `pyproject.toml` to route this location to agents serving that queue name:
40+
41+
```toml title="pyproject.toml"
42+
[tool.dg.project]
43+
root_module = "hybrid_location"
44+
agent_queue = "hybrid-queue"
45+
```
46+
47+
For a full `build.yaml` specification, see the [build.yaml reference](/deployment/dagster-plus/management/build-yaml).
48+
49+
## Full working example
50+
51+
A complete example is available in the [Dagster repository](https://github.com/dagster-io/dagster/tree/master/examples/docs_projects/project_serverless_hybrid).

0 commit comments

Comments
 (0)