Skip to content

fix(cli): remove unused backend flag from compose up - #1037

Draft
VedantMadane wants to merge 2 commits into
docker:mainfrom
VedantMadane:fix-compose-backend-flag
Draft

VedantMadane wants to merge 2 commits into
docker:mainfrom
VedantMadane:fix-compose-backend-flag

Conversation

@VedantMadane

Copy link
Copy Markdown
Contributor

Summary

Fixes #1036

In cmd/cli/commands/compose.go,
ewUpCommand() defined a --backend flag variable �ackend but never passed it to desktopClient.ConfigureBackend(...). As a result, passing --backend was a silent no-op while compose metadata still advertised --backend parameter to UI consumers.

This PR removes the dead --backend flag variable and flag binding from
ewUpCommand() and removes the unused llamacpp import.

@sourcery-ai sourcery-ai Bot left a comment

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.

Hey - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@doringeman

Copy link
Copy Markdown
Contributor

Hello @VedantMadane,

I need to look into why this is here. Indeed backend is not present in https://github.com/docker/compose/blob/main/pkg/compose/model.go.

Copilot AI left a comment

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.

Copilot review overview

🟡 Changes recommended

Regenerate and commit the reference documentation so it no longer advertises the removed flag.

Get a fresh assessment by requesting another Copilot review.

Review effort: Lite
Findings: 1 High severity

Open (1)
What changed in this PR

Removes the unused --backend option from docker model compose up.

Changes:

  • Removes the dead flag, binding, and unused llamacpp import.
  • Reference documentation still requires regeneration to remove the obsolete option.
File Description
cmd/​cli/​commands/​compose.go Removes the unused backend flag and import.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@@ -127,7 +125,6 @@ func newUpCommand() *cobra.Command {
c.Flags().StringArrayVar(&models, "model", nil, "model to use")
c.Flags().Int64Var(&ctxSize, "context-size", -1, "context size for the model")
c.Flags().StringVar(&rawRuntimeFlags, "runtime-flags", "", "raw runtime flags to pass to the inference engine")

Copilot AI left a comment

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.

Copilot review overview

🔵 Needs a closer look

Regenerate and include the updated CLI reference documentation.

Review effort: Lite
Findings: 1 High severity

Open (1)

Copilot AI left a comment

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.

Copilot review overview

🔵 Needs a closer look

Regenerate and commit the Compose reference documentation to remove the stale --backend entry.

Review effort: Lite
Findings: 1 High severity

Open (1)

Signed-off-by: Vedant Madane <6527493+VedantMadane@users.noreply.github.com>
@ericcurtin

Copy link
Copy Markdown
Contributor

Change itself is clean, but doringeman flagged that the right fix might be wiring the flag instead of removing it, that's still unresolved, and CI hasn't run on this yet. Please get maintainer agreement on the approach and a green CI run. Also, model-runner is being deprecated in favor of llmman, please open future PRs there instead. Marking as draft, please mark ready for review once addressed.

@ericcurtin
ericcurtin marked this pull request as draft September 26, 2026 14:21
@VedantMadane

Copy link
Copy Markdown
Contributor Author

Understood, thank you @ericcurtin and @doringeman. If the plan is to wire --backend\ through Compose instead, or given the deprecation in favor of \llmman, please let me know how you would prefer to proceed here or if we should close this in favor of \llmman.

This branch has not been deployed

No deployments
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.

compose up: --backend flag is accepted but never applied

4 participants