Skip to content

Keep the start command field, drop the adapter reads behind it - #3157

Open
HarshMN2345 wants to merge 2 commits into
mainfrom
fix/sites-hide-start-command
Open

Keep the start command field, drop the adapter reads behind it#3157
HarshMN2345 wants to merge 2 commits into
mainfrom
fix/sites-hide-start-command

Conversation

@HarshMN2345

Copy link
Copy Markdown
Member

The field stays where it is. What goes is the code reading startCommand off a framework adapter: the SDK never declared it and the API no longer sends it, so the prefill and the placeholder were pointing at nothing, and Reset restored a value that does not exist.

Also stop carrying a start command across a framework or adapter change - it names an entrypoint only the previous framework has - and send it only for the ssr adapter, matching the fallbackFile line beside it.

What does this PR do?

(Provide a description of what this PR does.)

Test Plan

(Write your test plan here. If you changed any code, please provide us with clear instructions on how you verified your changes work.)

Related PRs and Issues

(If this PR is related to any other PR or resolves any issue or related to any issue link all related PR and issues here.)

Have you read the Contributing Guidelines on issues?

(Write your answer here.)

The field stays where it is. What goes is the code reading startCommand
off a framework adapter: the SDK never declared it and the API no longer
sends it, so the prefill and the placeholder were pointing at nothing, and
Reset restored a value that does not exist.

Also stop carrying a start command across a framework or adapter change -
it names an entrypoint only the previous framework has - and send it only
for the ssr adapter, matching the fallbackFile line beside it.
@appwrite

appwrite Bot commented Aug 13, 2026

Copy link
Copy Markdown

Console (appwrite/console)

Project ID: 688b7bf400350cbd60e9

Sites (1)
Site Status Logs Preview QR
console-stage
688b7cf6003b1842c9dc
Queued Queued View Logs Preview URL QR Code

Tip

Our Discord community has grown to 24K developers, and counting

@greptile-apps

greptile-apps Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR keeps start-command editing while removing unsupported framework-adapter defaults, clears the value across framework or adapter changes, and limits API submission to SSR sites.

  • Adds start-command support to manual, repository, and one-click site creation forms.
  • Clears framework-specific start commands when configuration changes.
  • Shows and submits the field only for SSR adapters.

Confidence Score: 4/5

The PR is not yet safe to merge because URL-prefilled start commands can survive an SSR framework change and be submitted for the wrong framework.

The deploy flow makes hasCustomCommands permanently true when a start parameter is present, bypassing the only framework-change path that clears startCommand and allowing the stale entrypoint to reach sites.create.

Files Needing Attention: src/routes/(console)/project-[region]-[project]/sites/create-site/deploy/+page.svelte

Important Files Changed

Filename Overview
src/routes/(console)/project-[region]-[project]/sites/create-site/configuration.svelte Adds the SSR-only start-command field and clears it whenever the selected framework or adapter defaults change.
src/routes/(console)/project-[region]-[project]/sites/create-site/deploy/+page.svelte Adds URL-prefilled start-command support, but the custom-command guard lets that value survive subsequent SSR framework changes.
src/routes/(console)/project-[region]-[project]/sites/create-site/manual/+page.svelte Wires the start-command field through manual site creation.
src/routes/(console)/project-[region]-[project]/sites/create-site/repositories/repository-[repository]/+page.svelte Wires the start-command field through repository-based site creation.
src/routes/(console)/project-[region]-[project]/sites/site-[site]/settings/updateBuildSettings.svelte Removes adapter-derived start-command defaults, clears the value across configuration changes, and submits it only for SSR adapters.

Fix All in Greploop

Fix All in Claude Code Fix All in Codex

Prompt To Fix All With AI
### Issue 1
src/routes/(console)/project-[region]-[project]/sites/create-site/deploy/+page.svelte:117
**Start command survives framework changes**

When a deploy URL supplies a `start` parameter and the user selects a different SSR framework, `hasCustomCommands` prevents the framework-change effect from clearing `startCommand`, causing the previous framework's entrypoint to be submitted for the new framework and the deployment to fail at startup.

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Reviews (2): Last reviewed commit: "Clear the start command when the framewo..." | Re-trigger Greptile

The settings form already resets it; the create flows kept the previous
framework's entrypoint in state and submitted it, and kept sending it
after a switch to a framework that only builds static.

Reset it alongside the other adapter-derived fields in both places.

// Check if custom commands were provided via URL
hasCustomCommands = !!(installCommand || buildCommand || outputDirectory);
hasCustomCommands = !!(installCommand || buildCommand || startCommand || outputDirectory);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P1 Start command survives framework changes

When a deploy URL supplies a start parameter and the user selects a different SSR framework, hasCustomCommands prevents the framework-change effect from clearing startCommand, causing the previous framework's entrypoint to be submitted for the new framework and the deployment to fail at startup.

Knowledge Base Used: Functions and Sites

Prompt To Fix With AI
This is a comment left during a code review.
Path: src/routes/(console)/project-[region]-[project]/sites/create-site/deploy/+page.svelte
Line: 117

Comment:
**Start command survives framework changes**

When a deploy URL supplies a `start` parameter and the user selects a different SSR framework, `hasCustomCommands` prevents the framework-change effect from clearing `startCommand`, causing the previous framework's entrypoint to be submitted for the new framework and the deployment to fail at startup.

**Knowledge Base Used:** [Functions and Sites](https://app.greptile.com/appwrite/-/custom-context/knowledge-base/appwrite/console/-/docs/project-functions-sites.md)

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Fix in Claude Code Fix in Codex

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