Skip to content

fix(integrations): agy honors SPECKIT_INTEGRATION_AGY_EXTRA_ARGS#3347

Merged
mnriem merged 1 commit into
github:mainfrom
jawwad-ali:fix/agy-extra-args-env
Jul 7, 2026
Merged

fix(integrations): agy honors SPECKIT_INTEGRATION_AGY_EXTRA_ARGS#3347
mnriem merged 1 commit into
github:mainfrom
jawwad-ali:fix/agy-extra-args-env

Conversation

@jawwad-ali

Copy link
Copy Markdown
Contributor

Description

AgyIntegration.build_exec_args returned its argv in one line without calling _apply_extra_args_env_var():

# agy does not support --model or JSON output; both params are ignored
return [self._resolve_executable(), "--print", prompt]

So SPECKIT_INTEGRATION_AGY_EXTRA_ARGS was silently dropped — the same class of bug fixed for cursor-agent in #3265. (argv[0] already went through _resolve_executable(), so the _EXECUTABLE override worked; only the extra-args hook was missing.)

Fix

Append self._apply_extra_args_env_var(args) after the positional prompt, matching the devin integration's shape ([exe, "-p", prompt] then hook). agy still ignores model/output_json as before.

Testing

Added to the existing TestAgyBuildExecArgs:

  • test_build_exec_args_honors_extra_args: with the env var set, argv == ['agy','--print','my prompt','--verbose']. Fails before (--verbose absent — verified by source-stash), passes after;
  • executable-override test.

The 3 existing tests pin the env-unset shape and stay green. uvx ruff check clean.

AI Disclosure

  • I did use AI assistance (describe below)

Found and fixed with Claude Code (Claude Fable 5) under my direction. AI flagged agy as another integration skipping the extra-args hook; I confirmed it, verified fail-before/pass-after, and reviewed the diff.

AgyIntegration.build_exec_args returned [exe, '--print', prompt] without
calling _apply_extra_args_env_var(), so the documented per-integration
extra-args env hook was silently dropped for agy — same class as the
cursor-agent fix github#3265. Append the hook after the positional prompt,
matching the devin integration's shape. agy still ignores model/output
as before.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

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.

Pull request overview

Fixes a CLI-dispatch parity gap in AgyIntegration: build_exec_args() now honors the documented SPECKIT_INTEGRATION_AGY_EXTRA_ARGS hook by routing through _apply_extra_args_env_var(), matching behavior of other CLI-dispatch integrations (e.g., devin, cursor-agent).

Changes:

  • Update AgyIntegration.build_exec_args() to append operator-supplied extra args from SPECKIT_INTEGRATION_AGY_EXTRA_ARGS.
  • Add regression tests verifying both SPECKIT_INTEGRATION_AGY_EXTRA_ARGS and SPECKIT_INTEGRATION_AGY_EXECUTABLE overrides are honored.
Show a summary per file
File Description
src/specify_cli/integrations/agy/__init__.py Applies _apply_extra_args_env_var() to agy’s exec argv to honor SPECKIT_INTEGRATION_AGY_EXTRA_ARGS.
tests/integrations/test_integration_agy.py Adds regression coverage for extra-args and executable override env vars in build_exec_args().

Review details

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 2/2 changed files
  • Comments generated: 0
  • Review effort level: Low

@mnriem mnriem merged commit 0151d23 into github:main Jul 7, 2026
12 checks passed
@mnriem

mnriem commented Jul 7, 2026

Copy link
Copy Markdown
Collaborator

Thank you!

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.

3 participants