adutra commented on code in PR #4454: URL: https://github.com/apache/polaris/pull/4454#discussion_r3258929261
########## AGENTS.md: ########## @@ -66,6 +66,30 @@ assumptions and running with them without checking. --- +## Do Not Treat Issues As Specifications [DISCIPLINE] + +A GitHub issue is a starting point for investigation, not an implementation plan. +Before making an issue-driven change, verify that the requested behavior is still +missing and that the proposed fix actually addresses the stated problem. + +Required workflow: + +1. Trace the current code path related to the issue. +2. Search for existing validation, tests, build tasks, or runtime behavior that may + already cover the requested case. +3. Compare the issue's requested failure modes with the change you intend to make. + If the change only addresses part of the issue, use `Related to #NNN`, not + `Fixes #NNN`. +4. Do not add redundant checks. If existing code already fails, validates, or tests + the scenario, explain that finding instead of opening a code-change PR. +5. Do not materialize unbounded inputs just to perform existence checks. Prefer + streaming, short-circuiting, indexed lookups, or existing APIs. If collecting is + necessary, the bound must be obvious from the code or explained in the PR. Review Comment: It took me 30 seconds to understand what you meant by `materialize unbounded inputs` 😅 - I think it would be beneficial to agents (and humans) to clarify the context here: > 5. **When fetching results from the database (on any external datasource),** do not materialize unbounded inputs... But once this clarification is in, I'm not sure that this item belongs in this list: all other items are about validating the issue, but this one is an implementation guideline. I wonder if this item shouldn't be moved to `CONTRIBUTING.md`? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
