Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add AssetGraphView.create_latest_time_window_slice #20352

Merged
merged 2 commits into from
Mar 13, 2024
Merged

Conversation

schrockn
Copy link
Member

@schrockn schrockn commented Mar 8, 2024

Summary & Motivation

Add create_latest_time_window_slice property to AssetGraphView. It gets an AssetSlice of the latest time window relative to the effective date of the AssetGraphView.

How I Tested These Changes

BK

@schrockn
Copy link
Member Author

schrockn commented Mar 8, 2024

@schrockn schrockn force-pushed the asset-graph-view-1 branch from f976741 to 7ffcdd1 Compare March 8, 2024 07:49
@schrockn schrockn force-pushed the asset-graph-view-2 branch 2 times, most recently from 1f5e51f to 90a0736 Compare March 8, 2024 09:31
@schrockn schrockn force-pushed the asset-graph-view-2 branch 2 times, most recently from aa23d4e to 0c64516 Compare March 8, 2024 10:18
@schrockn schrockn marked this pull request as ready for review March 8, 2024 12:49
@schrockn schrockn force-pushed the asset-graph-view-1 branch from 6210591 to 99cd2dc Compare March 8, 2024 14:22
@schrockn schrockn force-pushed the asset-graph-view-2 branch from 0c64516 to fb2c810 Compare March 8, 2024 14:23
def latest_time_window_slice(self) -> "AssetSlice":
"""Returns the latest time window for the asset slice.

If the asset slice is time-window-partitiond (e.g. daily, hourly),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo

@schrockn schrockn force-pushed the asset-graph-view-1 branch 2 times, most recently from b92518d to 6bb9be9 Compare March 9, 2024 12:27
@schrockn schrockn force-pushed the asset-graph-view-2 branch from fb2c810 to aa748ae Compare March 9, 2024 12:27
@schrockn schrockn mentioned this pull request Mar 10, 2024
@schrockn schrockn force-pushed the asset-graph-view-2 branch from aa748ae to 5bfd3c4 Compare March 10, 2024 18:18
@schrockn schrockn force-pushed the asset-graph-view-1 branch 2 times, most recently from b2a2725 to 25abc9f Compare March 11, 2024 09:36
@schrockn schrockn force-pushed the asset-graph-view-2 branch from 5bfd3c4 to 8e151ba Compare March 11, 2024 09:36
@schrockn schrockn force-pushed the asset-graph-view-1 branch from 25abc9f to 1a3f697 Compare March 11, 2024 17:27
@schrockn schrockn force-pushed the asset-graph-view-2 branch from 8e151ba to 1d2e500 Compare March 11, 2024 17:27
Base automatically changed from asset-graph-view-1 to master March 11, 2024 18:03
@schrockn schrockn force-pushed the asset-graph-view-2 branch 3 times, most recently from fdc715f to 1077b0d Compare March 12, 2024 12:39
Comment on lines +161 to +163
def time_windows(self) -> Sequence[TimeWindow]:
"""Get the time windows for the asset slice. Only supports explicitly time-windowed partitions for now."""
# Only supports explicitly time-windows partitions for now
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm going to change this to support all time windows later. In a bit of rebase hell right now.

@schrockn schrockn changed the title Add latest_time_window Add AssetGraphView.create_latest_time_window_slice Mar 12, 2024
@schrockn schrockn requested a review from smackesey March 12, 2024 12:48
Copy link
Member Author

@schrockn schrockn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@smackesey this is ready to look at

@schrockn schrockn force-pushed the asset-graph-view-2 branch from 9e70a03 to b0423d4 Compare March 13, 2024 15:12
Copy link

Deploy preview for dagit-core-storybook ready!

✅ Preview
https://dagit-core-storybook-3owasne8j-elementl.vercel.app
https://asset-graph-view-2.core-storybook.dagster-docs.io

Built with commit b0423d4.
This pull request is being automatically deployed with vercel-action

Copy link

Deploy preview for dagster-docs ready!

Preview available at https://dagster-docs-aqw6hzff1-elementl.vercel.app
https://asset-graph-view-2.dagster.dagster-docs.io

Direct link to changed pages:

Copy link

Deploy preview for dagit-storybook ready!

✅ Preview
https://dagit-storybook-hq2y6m7nf-elementl.vercel.app
https://asset-graph-view-2.components-storybook.dagster-docs.io

Built with commit b0423d4.
This pull request is being automatically deployed with vercel-action

@schrockn
Copy link
Member Author

schrockn commented Mar 13, 2024

Merge activity

  • Mar 13, 1:59 PM EDT: @schrockn started a stack merge that includes this pull request via Graphite.
  • Mar 13, 2:00 PM EDT: @schrockn merged this pull request with Graphite.

@schrockn schrockn merged commit 4b93014 into master Mar 13, 2024
4 checks passed
@schrockn schrockn deleted the asset-graph-view-2 branch March 13, 2024 18:00
PedramNavid pushed a commit that referenced this pull request Mar 28, 2024
## Summary & Motivation

Add `create_latest_time_window_slice` property to `AssetGraphView`.  It gets an `AssetSlice` of the latest time window relative to the effective date of the `AssetGraphView`.

## How I Tested These Changes

BK
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants