Skip to content

Plane Runner#427

Open
danciaclara wants to merge 2 commits intomasterfrom
plane-runner
Open

Plane Runner#427
danciaclara wants to merge 2 commits intomasterfrom
plane-runner

Conversation

@danciaclara
Copy link
Copy Markdown
Collaborator

@danciaclara danciaclara commented Apr 9, 2026

Description

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • Feature (non-breaking change which adds functionality)
  • Improvement (change that would cause existing functionality to not work as expected)
  • Code refactoring
  • Performance improvements
  • Documentation update

Screenshots and Media (if applicable)

Test Scenarios

References

Summary by CodeRabbit

  • Documentation
    • Added comprehensive Plane Runner docs covering activation, Scripts & Functions building blocks, sandbox globals, built-in utilities, security model, execution limits, and end-to-end examples.
  • Documentation
    • Added a new sidebar link under "Advanced management" to the Plane Runner documentation.

@vercel
Copy link
Copy Markdown

vercel bot commented Apr 9, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
docs Ready Ready Preview, Comment Apr 12, 2026 2:25pm

Request Review

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 9, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 4504d3ec-3df6-4387-b0dd-7131c7110b4e

📥 Commits

Reviewing files that changed from the base of the PR and between 0450c46 and f429253.

📒 Files selected for processing (2)
  • docs/.vitepress/config.ts
  • docs/automations/plane-runner.md
✅ Files skipped from review due to trivial changes (2)
  • docs/.vitepress/config.ts
  • docs/automations/plane-runner.md

📝 Walkthrough

Walkthrough

Added documentation and site navigation for Plane Runner: a new secure, sandboxed JavaScript/TypeScript execution engine for automations. Includes activation steps, Scripts/Functions building blocks, sandbox globals, security model, execution limits, built-in utilities, and examples.

Changes

Cohort / File(s) Summary
Documentation Navigation
docs/.vitepress/config.ts
Inserted "Plane Runner" sidebar entry under the Advanced management section.
Plane Runner Documentation
docs/automations/plane-runner.md
Added new comprehensive doc describing Plane Runner activation, Scripts and Functions, sandbox globals, built-in system functions/scripts, security model (allowed/blocked capabilities, HTTP allowlisting), execution limits, and multiple end-to-end examples.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 I hopped through docs to plant this seed,

Scripts and Functions to run at speed.
Sandbox safe, with globals to share,
Automations blossom with careful care.
Plane Runner hums — a rabbit's small cheer!

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title 'Plane Runner' is concise and directly relates to the main change—adding comprehensive documentation for the Plane Runner feature, including a new config entry and a detailed documentation page.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch plane-runner

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a 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

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
docs/.vitepress/config.ts (1)

1-1: ⚠️ Potential issue | 🔴 Critical

Fix formatting issues reported by oxfmt.

The pipeline is failing because oxfmt --check detected formatting issues in this file. Run oxfmt (without --check) to automatically fix the formatting.

Run the following to fix:

oxfmt docs/.vitepress/config.ts
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/.vitepress/config.ts` at line 1, Run the code formatter oxfmt to fix the
formatting issues detected (specifically around the import statement like
`import { readFileSync } from "fs";`), e.g., run oxfmt on the file to apply the
changes, verify the import and surrounding file now pass `oxfmt --check`, then
stage and commit the reformatted file.
🧹 Nitpick comments (3)
docs/automations/plane-runner.md (3)

252-303: Clarify undefined variable in code example.

The example on line 294 uses otherItemId without defining it. While this is illustrative documentation, users copying the example will encounter an error. Consider adding a comment or defining the variable to make the example more complete.

📝 Suggested improvement
 // Create a relation
+const otherItemId = "some-other-work-item-id"; // ID of the work item to link to
 await Plane.workItems.relations.create(
   workspaceSlug, projectId, workItemId, {
     relation_type: "relates_to",
     issues: [otherItemId]
   }
 );
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/automations/plane-runner.md` around lines 252 - 303, The documentation
example uses an undefined variable otherItemId in the
Plane.workItems.relations.create call; update the example to either define
otherItemId (e.g., const otherItemId = "<existingWorkItemId>") or add an inline
comment above that line explaining that otherItemId should be replaced with the
ID of an existing work item, so readers copying the snippet won't get a
ReferenceError when using Plane.workItems.relations.create.

402-442: Consider clarifying the API response pattern.

The example uses statesResult.results || statesResult (line 416) to handle different response shapes from Plane.states.list(). This pattern appears in multiple examples. If the API response format is inconsistent, it might be worth documenting why this fallback is necessary, or ensuring the API returns a consistent format.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/automations/plane-runner.md` around lines 402 - 442, The example's
fallback "statesResult.results || statesResult" in main when calling
Plane.states.list causes ambiguity; update main to normalize the API response
explicitly by checking the returned shape (e.g., if Array.isArray(statesResult)
use it, otherwise use statesResult.results) or introduce a small helper like
normalizeResults used by Plane.states.list callers to always return an array;
update references in main (statesResult, states, stateGroupMap) to use the
normalized array and add a short comment explaining the normalization so future
examples show a consistent, documented pattern.

312-318: Document how ENV variables are securely configured.

The documentation mentions using ENV for secrets and API keys but doesn't explain how these environment variables are securely stored, configured, or managed within Plane. Adding a brief explanation or link to docs on setting up environment variables would help users handle sensitive data correctly.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/automations/plane-runner.md` around lines 312 - 318, Add a short section
after the ENV example explaining how environment variables (ENV) are securely
configured and managed in Plane: describe using Plane's secrets/variables
feature (or CLI) to set EXTERNAL_API_KEY and SLACK_WEBHOOK without committing
them to source, mention that values are stored encrypted and injected at
runtime, advise against hardcoding secrets and recommend rotating keys and using
least-privilege scopes, and include a brief pointer sentence linking to the
Plane docs page on configuring environment/secret variables for full setup
instructions.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@docs/automations/plane-runner.md`:
- Line 1: The file docs/automations/plane-runner.md has oxfmt formatting errors;
run the formatter to fix them by executing oxfmt on that file (e.g., run oxfmt
docs/automations/plane-runner.md), review the resulting changes to ensure they
match project style, and commit the updated file so the CI oxfmt --check step
passes.

---

Outside diff comments:
In `@docs/.vitepress/config.ts`:
- Line 1: Run the code formatter oxfmt to fix the formatting issues detected
(specifically around the import statement like `import { readFileSync } from
"fs";`), e.g., run oxfmt on the file to apply the changes, verify the import and
surrounding file now pass `oxfmt --check`, then stage and commit the reformatted
file.

---

Nitpick comments:
In `@docs/automations/plane-runner.md`:
- Around line 252-303: The documentation example uses an undefined variable
otherItemId in the Plane.workItems.relations.create call; update the example to
either define otherItemId (e.g., const otherItemId = "<existingWorkItemId>") or
add an inline comment above that line explaining that otherItemId should be
replaced with the ID of an existing work item, so readers copying the snippet
won't get a ReferenceError when using Plane.workItems.relations.create.
- Around line 402-442: The example's fallback "statesResult.results ||
statesResult" in main when calling Plane.states.list causes ambiguity; update
main to normalize the API response explicitly by checking the returned shape
(e.g., if Array.isArray(statesResult) use it, otherwise use
statesResult.results) or introduce a small helper like normalizeResults used by
Plane.states.list callers to always return an array; update references in main
(statesResult, states, stateGroupMap) to use the normalized array and add a
short comment explaining the normalization so future examples show a consistent,
documented pattern.
- Around line 312-318: Add a short section after the ENV example explaining how
environment variables (ENV) are securely configured and managed in Plane:
describe using Plane's secrets/variables feature (or CLI) to set
EXTERNAL_API_KEY and SLACK_WEBHOOK without committing them to source, mention
that values are stored encrypted and injected at runtime, advise against
hardcoding secrets and recommend rotating keys and using least-privilege scopes,
and include a brief pointer sentence linking to the Plane docs page on
configuring environment/secret variables for full setup instructions.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 25ba153e-df4b-41d9-8176-a3ffe3f3dd21

📥 Commits

Reviewing files that changed from the base of the PR and between c467a3d and 0450c46.

📒 Files selected for processing (2)
  • docs/.vitepress/config.ts
  • docs/automations/plane-runner.md

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.

1 participant