feat: improve cookie extraction diagnostics and add doctor command

- Add _diagnose_keychain_issues() for macOS Keychain/SSH detection
- Extraction functions now return (cookies, diagnostics) tuples
- Error messages include actionable Keychain hints (e.g. unlock-keychain)
- Add 'twitter doctor' diagnostic command for troubleshooting
- Enhance bug_report.yml with browser/access method/diagnostics fields
- Expand README troubleshooting (EN+CN) with Keychain/SSH solutions
- Add 5 new tests for Keychain diagnostics

Closes #11
This commit is contained in:
jackwener
2026-03-11 16:53:06 +08:00
parent 47be88e62d
commit 60e1e7c580
5 changed files with 366 additions and 36 deletions

View File

@@ -21,6 +21,31 @@ body:
- Other
validations:
required: true
- type: dropdown
id: browser
attributes:
label: Browser (for cookie extraction)
options:
- Arc
- Chrome
- Edge
- Firefox
- Brave
- Other / N/A (using env vars)
validations:
required: true
- type: dropdown
id: access_method
attributes:
label: Access Method
description: How are you accessing the machine where twitter-cli runs?
options:
- Local terminal
- SSH
- Docker / container
- Other
validations:
required: true
- type: textarea
id: description
attributes:
@@ -41,6 +66,12 @@ body:
label: Steps to reproduce
description: "Commands or steps to reproduce the issue. Use `twitter -v <command>` for debug output."
render: bash
- type: textarea
id: diagnostics
attributes:
label: Diagnostics
description: "Paste the output of `twitter doctor` here. This helps us diagnose cookie and auth issues quickly."
render: text
- type: textarea
id: logs
attributes: