-
Notifications
You must be signed in to change notification settings - Fork 0
chore: Workflow to Sync Platform Subtree on Pushes to Main #734
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
Conversation
WalkthroughA new workflow Changes
Sequence Diagram(s)sequenceDiagram
participant GitHub
participant ThisRepo
participant PlatformRepo
GitHub->>ThisRepo: Push to main
ThisRepo->>PlatformRepo: Trigger reusable workflow (subtree_pull_reusable.yaml)
Suggested reviewers
Poem
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (2)
.github/workflows/trigger_platform_subtree_pull.yaml (2)
3-6
: Nit: comment clarity. The note "chronon's main" may confuse; use "this repo's main branch" instead.
10-10
: Add newline at EOF. Required by YAML lint.🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 10-10: no new line character at the end of file
(new-line-at-end-of-file)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro (Legacy)
📒 Files selected for processing (1)
.github/workflows/trigger_platform_subtree_pull.yaml
(1 hunks)
🧰 Additional context used
🪛 YAMLlint (1.35.1)
.github/workflows/trigger_platform_subtree_pull.yaml
[error] 10-10: no new line character at the end of file
(new-line-at-end-of-file)
🔇 Additional comments (1)
.github/workflows/trigger_platform_subtree_pull.yaml (1)
1-2
: Looks good. Descriptive workflow name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
♻️ Duplicate comments (1)
.github/workflows/trigger_platform_subtree_pull.yaml (1)
8-9
: 🛠️ Refactor suggestionPin reusable workflow to a commit SHA
Avoid breakage by replacing@main
with a specific commit SHA.- uses: zipline-ai/platform/.github/workflows/subtree_pull_reusable.yaml@main + uses: zipline-ai/platform/.github/workflows/subtree_pull_reusable.yaml@<commit-SHA>
🧹 Nitpick comments (1)
.github/workflows/trigger_platform_subtree_pull.yaml (1)
10-10
: Add newline at end of file
Ensure POSIX compliance by ending the file with a newline.secrets: inherit # Passes all secrets (needed for the deploy key) +
🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 10-10: no new line character at the end of file
(new-line-at-end-of-file)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro (Legacy)
📒 Files selected for processing (1)
.github/workflows/trigger_platform_subtree_pull.yaml
(1 hunks)
🧰 Additional context used
🪛 YAMLlint (1.35.1)
.github/workflows/trigger_platform_subtree_pull.yaml
[error] 10-10: no new line character at the end of file
(new-line-at-end-of-file)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
♻️ Duplicate comments (2)
.github/workflows/trigger_platform_subtree_pull.yaml (2)
3-5
: Restrict to main branch Uncomment thebranches: [ main ]
filter so this only runs on main pushes.
10-10
: Pin reusable workflow Use a specific commit SHA instead of@main
to avoid future breakage.
🧹 Nitpick comments (1)
.github/workflows/trigger_platform_subtree_pull.yaml (1)
11-11
: Add EOF newline Insert a trailing newline to satisfy YAML lint.🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 11-11: no new line character at the end of file
(new-line-at-end-of-file)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro (Legacy)
📒 Files selected for processing (1)
.github/workflows/trigger_platform_subtree_pull.yaml
(1 hunks)
🧰 Additional context used
🪛 YAMLlint (1.35.1)
.github/workflows/trigger_platform_subtree_pull.yaml
[error] 11-11: no new line character at the end of file
(new-line-at-end-of-file)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
♻️ Duplicate comments (2)
.github/workflows/trigger_platform_subtree_pull.yaml (2)
4-5
: Restrict workflow to only main branch.
Uncomment the branch filter so it doesn’t trigger on every push:on: - push: -# branches: [ main ] # Run when changes land in chronon's main + push: + branches: [ main ] # Run when changes land in chronon's main
8-9
: Pin reusable workflow to a commit SHA.
Avoid breakage ifmain
changes by referencing a fixed SHA:- uses: zipline-ai/platform/.github/workflows/subtree_pull_reusable.yaml@main + uses: zipline-ai/platform/.github/workflows/subtree_pull_reusable.yaml@<commit-SHA>
🧹 Nitpick comments (2)
.github/workflows/trigger_platform_subtree_pull.yaml (2)
10-10
: Add newline at end of file.
Ensures YAML linter passes.🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 10-10: no new line character at the end of file
(new-line-at-end-of-file)
10-10
: Scope secrets instead of inheriting all.
If possible, list only the required secrets to reduce risk.🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 10-10: no new line character at the end of file
(new-line-at-end-of-file)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro (Legacy)
📒 Files selected for processing (1)
.github/workflows/trigger_platform_subtree_pull.yaml
(1 hunks)
🧰 Additional context used
🪛 YAMLlint (1.35.1)
.github/workflows/trigger_platform_subtree_pull.yaml
[error] 10-10: no new line character at the end of file
(new-line-at-end-of-file)
🔇 Additional comments (1)
.github/workflows/trigger_platform_subtree_pull.yaml (1)
1-2
: Workflow name is clear.
This succinctly describes the action’s purpose.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (3)
.github/workflows/subtree_pull_test.yaml (3)
29-47
: Simplify SSH setup usingwebfactory/ssh-agent
You can replace the manual SSH key, known_hosts, and agent setup with a single action step:- uses: webfactory/[email protected] with: ssh-private-key: ${{ secrets.CHRONON_REPO_DEPLOY_KEY }}This reduces boilerplate and improves maintainability.
🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 32-32: trailing spaces
(trailing-spaces)
[error] 35-35: trailing spaces
(trailing-spaces)
[error] 39-39: trailing spaces
(trailing-spaces)
[error] 47-47: trailing spaces
(trailing-spaces)
49-53
: Handle no-op subtree pulls gracefully
git subtree pull
exits non-zero when there’s no update. Prevent pipeline failures by swallowing that specific case:- git subtree pull --prefix=chronon chronon main --message="chore: update chronon subtree" + git subtree pull --prefix=chronon chronon main --message="chore: update chronon subtree" || echo "no subtree changes"🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 50-50: trailing spaces
(trailing-spaces)
32-32
: Remove trailing spaces & ensure newline at EOF
YAMLlint flagged trailing whitespace on lines 32, 35, 39, 47, and 50, plus missing final newline. Cleaning these up will satisfy the linter.Also applies to: 35-35, 39-39, 47-47, 50-50, 55-55
🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 32-32: trailing spaces
(trailing-spaces)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro (Legacy)
📒 Files selected for processing (1)
.github/workflows/subtree_pull_test.yaml
(1 hunks)
🧰 Additional context used
🪛 YAMLlint (1.35.1)
.github/workflows/subtree_pull_test.yaml
[error] 32-32: trailing spaces
(trailing-spaces)
[error] 35-35: trailing spaces
(trailing-spaces)
[error] 39-39: trailing spaces
(trailing-spaces)
[error] 47-47: trailing spaces
(trailing-spaces)
[error] 50-50: trailing spaces
(trailing-spaces)
[error] 55-55: no new line character at the end of file
(new-line-at-end-of-file)
🔇 Additional comments (3)
.github/workflows/subtree_pull_test.yaml (3)
11-20
: Checkout platform repo step looks solid
Usingactions/checkout@v4
with SSH key, full fetch depth, explicitref: main
, andpersist-credentials: false
aligns with subtree requirements.
21-25
: Git user config is correct
Setting both name and email ensures commits from Actions are attributed properly.
54-55
: Push changes step is correct
Pushing via SSH matches the checkout config and will publish the subtree update commit.🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 55-55: no new line character at the end of file
(new-line-at-end-of-file)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (2)
.github/workflows/test_subtree_pull.yaml (2)
31-31
: Remove trailing whitespace.
Trim trailing spaces on these lines to satisfy YAML lint.Also applies to: 34-34, 38-38, 46-46, 49-49
🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 31-31: trailing spaces
(trailing-spaces)
54-54
: Add newline at end of file.
Ensure a final newline to pass YAML lint.🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 54-54: no new line character at the end of file
(new-line-at-end-of-file)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro (Legacy)
📒 Files selected for processing (1)
.github/workflows/test_subtree_pull.yaml
(1 hunks)
🧰 Additional context used
🪛 YAMLlint (1.35.1)
.github/workflows/test_subtree_pull.yaml
[error] 31-31: trailing spaces
(trailing-spaces)
[error] 34-34: trailing spaces
(trailing-spaces)
[error] 38-38: trailing spaces
(trailing-spaces)
[error] 46-46: trailing spaces
(trailing-spaces)
[error] 49-49: trailing spaces
(trailing-spaces)
[error] 54-54: no new line character at the end of file
(new-line-at-end-of-file)
🔇 Additional comments (3)
.github/workflows/test_subtree_pull.yaml (3)
11-19
: Checkout step configuration is correct.
fetch-depth: 0
, SSH key usage, andref: main
are properly set.
20-23
: Git user config step is fine.
User name/email are set for proper commit attribution.
24-52
: Subtree pull commands look solid.
SSH setup, remote addition, fetch, andgit subtree pull
are correctly implemented.🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 31-31: trailing spaces
(trailing-spaces)
[error] 34-34: trailing spaces
(trailing-spaces)
[error] 38-38: trailing spaces
(trailing-spaces)
[error] 46-46: trailing spaces
(trailing-spaces)
[error] 49-49: trailing spaces
(trailing-spaces)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
♻️ Duplicate comments (1)
.github/workflows/trigger_platform_subtree_pull.yaml (1)
8-9
: 🛠️ Refactor suggestionPin reusable workflow to a commit SHA
- uses: zipline-ai/platform/.github/workflows/subtree_pull_reusable.yaml@main + uses: zipline-ai/platform/.github/workflows/subtree_pull_reusable.yaml@<commit-SHA>
🧹 Nitpick comments (1)
.github/workflows/trigger_platform_subtree_pull.yaml (1)
10-10
: Add trailing newline
[yamllint]🧰 Tools
🪛 YAMLlint (1.35.1)
[error] 10-10: no new line character at the end of file
(new-line-at-end-of-file)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro (Legacy)
📒 Files selected for processing (1)
.github/workflows/trigger_platform_subtree_pull.yaml
(1 hunks)
🧰 Additional context used
🪛 YAMLlint (1.35.1)
.github/workflows/trigger_platform_subtree_pull.yaml
[error] 10-10: no new line character at the end of file
(new-line-at-end-of-file)
🔇 Additional comments (2)
.github/workflows/trigger_platform_subtree_pull.yaml (2)
1-2
: LGTM
[name is descriptive]
3-6
: Branch filter is correct
## Summary Create workflow to trigger platform subtree pull reusable workflow. Also deletes Push To Canary workflow as it will be triggered in the platform repo. ## Checklist - [ ] Added Unit Tests - [ ] Covered by existing CI - [ ] Integration tested - [ ] Documentation update <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Chores** - Added a new workflow to automate triggering subtree updates in an external platform repository when changes are pushed to the main branch. - Removed the "Push To Canary" workflow, discontinuing automated artifact builds, canary deployments, integration tests, and related notifications for the main branch. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
## Summary Create workflow to trigger platform subtree pull reusable workflow. Also deletes Push To Canary workflow as it will be triggered in the platform repo. ## Checklist - [ ] Added Unit Tests - [ ] Covered by existing CI - [ ] Integration tested - [ ] Documentation update <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Chores** - Added a new workflow to automate triggering subtree updates in an external platform repository when changes are pushed to the main branch. - Removed the "Push To Canary" workflow, discontinuing automated artifact builds, canary deployments, integration tests, and related notifications for the main branch. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
## Summary Create workflow to trigger platform subtree pull reusable workflow. Also deletes Push To Canary workflow as it will be triggered in the platform repo. ## Cheour clientslist - [ ] Added Unit Tests - [ ] Covered by existing CI - [ ] Integration tested - [ ] Documentation update <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Chores** - Added a new workflow to automate triggering subtree updates in an external platform repository when changes are pushed to the main branch. - Removed the "Push To Canary" workflow, discontinuing automated artifact builds, canary deployments, integration tests, and related notifications for the main branch. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
Summary
Create workflow to trigger platform subtree pull reusable workflow.
Also deletes Push To Canary workflow as it will be triggered in the platform repo.
Checklist
Summary by CodeRabbit