Repository navigation
Fix search, mail handling and bridge errors; propose separate access-control changes - #27
Open
reinhardullrich wants to merge 7 commits into
Open
reinhardullrich wants to merge 7 commits into
reinhardullrich wants to merge 7 commits into
Conversation
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.
Scope and review order
Hi Vitalii, thanks for Thunderbird CLI. We have been using and testing a fork with a real Thunderbird installation and would like to contribute the results back.
This is a mixed contribution, not a bug-fix-only PR. The sections below deliberately separate corrections to existing behavior from new capabilities and intentional, potentially breaking policy changes. Acceptance of the bug fixes does not imply agreement with the access-control design or removal of deletion operations.
Base:
vitalio-sh/thunderbird-cli:mainat465613d. Head:reinhardullrich/thunderbird-cli:mainat879d596. The fork uses onlymain; some commits combine fixes and features, so the sections below are a review map, not a claim that every category is already independently cherry-pickable. In particular,93178cband0b169dbmix categories.Existing upstream work
I checked open PR #26 before submitting this. It already addresses overlapping areas: whole-folder sorting, extension socket takeover, and signing documentation. This PR does not claim those fixes are new or ask you to replace your implementations. Please reconcile those overlaps when reviewing. This branch does not incorporate #26's separate full-text-search, timeout, or MCP tag-write changes.
1. Bug fixes: existing behavior was incorrect
hasMorecould misreport truncation, including within a final native page.headersOnlyafter successful retrieval, query attachment presence, and propagate errors. This is not a guarantee of permanent offline caching and may fetch mail.getFolderInfo; skip unsupported account-root count requests but traverse children and propagate real-folder failures.syncreported success without syncing; unsupported bridge flags were ignored; skill examples described unavailable arguments/protections.Tests for these paths are in the existing and added suites under
test/, especiallyreview-regressions.test.mjs,extension.test.mjs,quick-test.mjs,mcp-test.mjs, and the bridge tests.2. New feature: installation-wide access control
This is a proposed feature/design choice, not an upstream bug.
tb accessreports the loaded policy; editing a JSON file alone does not alter the running add-on.See
docs/ACCESS-CONTROL.md,extension/src/access-control.js,access.example.json, andtest/access-control.test.mjs.Boundaries: this is not per-user/per-account authorization or data-loss prevention. Raw MIME reads can contain attachment bytes even if dedicated exports are disabled. Thunderbird may autosave drafts. Disabling connector sending does not disable a person's Send button or protect against another program modifying the profile/add-on.
3. Other improvements and additions
inspect-composefor checking native reply linkage and attachments.4. Deliberate breaking changes / fork policy
These are intentional changes and require separate agreement. They are not bug fixes.
AGENTS.mdincludes our fork's main-only workflow. That paragraph is fork-specific, not a request to impose our Git workflow upstream.Verification and limitations
All ten local suites passed on the submitted code: CLI/mock, review regressions, access control, thread utilities, extension, optional MCP, bridge authentication, bridge security, draft integration, and local transport/build/service tests.
npm test npm run test:mcp npm run test:extension npm run test:bridge-auth npm run test:bridge-security npm run test:localLive checks were performed on Fedora Asahi ARM64 with Thunderbird 153.0.2. The installed private add-on is
2026.9.16.1; installed source matches the tested source. Checks covered account/folder listings, statistics, search/pagination, attachment metadata/download, native quoted reply/new-message preparation with attachments, and loaded policy. Test drafts were unsent; no messages were sent. The latest verification pass was read-only.No live destructive-operation tests were performed. Compatibility with every supported Thunderbird version, other operating systems, and upstream release publishing is not established by these checks. Sorted queries may scan many headers; search completeness still depends on Thunderbird's available data.
No private tokens, account configuration, mail contents, profile data, or private token-bearing XPIs are included in the submitted diff. Please review the correctness fixes independently from the policy choices above.