fix(#6831): add authentication preflight to Jira poller - #6833
Open
fullsend-ai-coder[bot] wants to merge 1 commit into
Open
fix(#6831): add authentication preflight to Jira poller#6833fullsend-ai-coder[bot] wants to merge 1 commit into
fullsend-ai-coder[bot] wants to merge 1 commit into
Conversation
The Jira poller silently succeeded with zero candidates when its configured credentials were invalid, because Jira treated unauthenticated requests as anonymous and returned empty results. This was indistinguishable from a genuinely quiet project. Add a GetMyself() call at the top of Poller.Run(), before JQL discovery, lock operations, or checkpoint writes. If the call fails (401/403) or returns an inactive account, Run returns a clear authentication error and exits non-zero without attempting any discovery. The error does not expose token or credential material. Tests cover auth failure (GetMyself error), inactive account, and successful preflight proceeding to normal discovery. Closes #6831
|
🤖 Finished Review · ✅ Success · Started 9:35 PM UTC · Completed 9:48 PM UTC Commit: Runtime: claude · Model: opus → claude-opus-4-6 · Effort: high · Cost: $3.59 |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
|
Risk Assessment: moderate (2/5) DetailsSmall focused bug fix (2 files, 105 lines) by a bot author with 50% test file ratio. No protected paths, security-sensitive files, CI, or dependency changes. Tier 2 churn in the jirapoll module is above average but mitigated by the change's narrow scope and clear acceptance criteria coverage. |
ReviewFindingsLow
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add an authentication preflight check (
GetMyself()) to the Jira poller'sRun()method, before JQL discovery, lock operations, or checkpoint writes. When credentials are missing, invalid, or belong to an inactive account, the poller now fails fast with a clear authentication error instead of silently returning zero candidates.Related Issue
Closes #6831
Changes
GetMyself()at the top ofPoller.Run()to verify credentials before any other Jira API callsauthentication preflight failederror on API failure (401/403) without exposing credential materialnewMockClient()to include a default active user so existing tests pass through the preflightTesting
TestRun_AuthPreflightFailure— verifies Run returns auth error and SearchIssues is never calledTestRun_AuthPreflightInactiveAccount— verifies inactive accounts are rejectedTestRun_AuthPreflightSuccess— verifies normal flow proceeds after successful preflightChecklist
!for breaking changes)Closes #6831
Post-script verification
agent/6831-jira-auth-preflight)e3620470427aa7c3bab339aef65cd1ca7552818c..HEAD)