Make live IBKR 2FA autofill target focused input#47
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: be0e5a8010
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| ) | ||
| time.sleep(PRE_ENTER_DELAY) | ||
| run_xdotool(["key", "--window", candidate.window_id, "Return"]) | ||
| type_totp_into_active_window(code) |
There was a problem hiding this comment.
Preserve window targeting when geometry is unavailable
This change now types the TOTP into the currently focused control, but focus_input_area is a no-op when candidate.width or candidate.height is missing. In that case submit_totp still calls type_totp_into_active_window, so the one-time code and Enter keystroke are sent to whichever window happened to be focused (not necessarily the IBKR auth dialog). Before this commit, the --window flag guaranteed delivery to candidate.window_id even without geometry data.
Useful? React with 👍 / 👎.
Summary
Tests