Skip to content

[SPARK-56449][INFRA] Skip pre-flight checks for code questions in AGENTS.md#55303

Open
szehon-ho wants to merge 2 commits intoapache:masterfrom
szehon-ho:skip-preflight-for-questions
Open

[SPARK-56449][INFRA] Skip pre-flight checks for code questions in AGENTS.md#55303
szehon-ho wants to merge 2 commits intoapache:masterfrom
szehon-ho:skip-preflight-for-questions

Conversation

@szehon-ho
Copy link
Copy Markdown
Member

@szehon-ho szehon-ho commented Apr 11, 2026

What changes were proposed in this pull request?

Updated AGENTS.md to skip the pre-flight checks when the user is only asking questions about the code or its behavior.

Why are the changes needed?

For every new AI agent session (cursor, claude code), a new questions like "what does function X do?" previously triggered git remote -v, a staleness check, a potential git fetch, git status, and a branch switch.

It's somewhat of a regression from the previous, more lightweight experience before AGENTS.md. It happens whenever open a tabs to start a different question session about the code.

Does this PR introduce any user-facing change?

No.

How was this patch tested?

Manual verification — this is a documentation-only change to AI agent instructions.

Was this patch authored or co-authored using generative AI tooling?

Generated-by: Cursor (Claude Opus 4)

@szehon-ho
Copy link
Copy Markdown
Member Author

szehon-ho commented Apr 11, 2026

Hi @cloud-fan , i noticed this is a bit of a regression for open a new tab and asking another question about the code (it does git fetch every time and potentially rebase), which is one of my main use case (though maybe its not the main use case for you or other experienced Spark devs :)) . wdyt?

AGENTS.md Outdated
## Pre-flight Checks

Before the first code read, edit, or test in a session, ensure a clean working environment. DO NOT skip these checks:
These checks apply to all tasks **except** answering questions about the code or its behavior. For those, skip these checks and work directly on whatever branch is currently checked out.
Copy link
Copy Markdown
Contributor

@cloud-fan cloud-fan Apr 13, 2026

Choose a reason for hiding this comment

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

ah, I think there is ambiguity here: do users want to ask questions about the code of latest master branch, or the current (may be dirty) local branch? Both are possible, but I think do not disturb the current branch is a better default. So +1 to your proposal.

Shall we just make a single change? Before the first code edit or running test in a session, ..

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

sure, done, thanks!

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