Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
2820795
chore: commit real asgard-mail app crate + repo hygiene (WP-0.1)
ilyk Jul 2, 2026
55527cf
license: relicense application to AGPL-3.0-only (WP-0.2)
ilyk Jul 2, 2026
e820e25
fix: stop UI from claiming success on unimplemented actions (WP-0.3)
ilyk Jul 2, 2026
70328d0
ci+build: fix CI, add rustfmt, format first-party crates, document bu…
ilyk Jul 2, 2026
937f6dc
feat(core): add SendRequest contract for the send pipeline (WP-1.1)
ilyk Jul 2, 2026
69f2b6a
feat: rewire send pipeline to SendRequest — no more dropped fields (W…
ilyk Jul 3, 2026
a72e864
feat(core): MIME encoder for outgoing mail (WP-1.2)
ilyk Jul 3, 2026
d1262ae
feat: signatures, draft saving, and working offline/scheduled outbox …
ilyk Jul 3, 2026
2e8c131
feat: backend actor module foundation (WP-2.1a)
ilyk Jul 3, 2026
e76b2bf
refactor: share BackendBridge as actor handle instead of Rc<RefCell> …
ilyk Jul 3, 2026
a8895a6
feat: run sends and Proton mailbox sync on the actor thread (WP-2.1c)
ilyk Jul 3, 2026
e67792f
feat: create generic IMAP/SMTP accounts from the setup dialog (WP-2.2…
ilyk Jul 3, 2026
6f48f13
fix: repair the 5 failing core tests — cache round-trip + Tantivy sea…
ilyk Jul 3, 2026
766fa55
fix: smart-mailbox Unread/Flagged predicates match real stored flags …
ilyk Jul 3, 2026
dd7f808
fix: apply + record migrations atomically to prevent startup brick (W…
ilyk Jul 3, 2026
5ce6ae4
chore: drop rustls dangerous_configuration + tighten release profile …
ilyk Jul 3, 2026
d1b9ee3
docs: metainfo developer/keywords, community docs, accurate README (P…
ilyk Jul 3, 2026
9e8b29d
test: fix asgard-oauth test compile error (WP-5.3)
ilyk Jul 3, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 45 additions & 0 deletions .agent/checkpoints/ACTIVE.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
{
"task_id": "P2-07-field-search",
"task_description": "Implement field-specific search filters supporting from:, to:, subject:, has:attachment prefixes",
"agent": "orchestrator",
"status": "completed",
"created_at": "2026-02-17T12:00:00Z",
"updated_at": "2026-02-17T12:15:00Z",
"progress": {
"current_step": 3,
"total_steps": 3,
"percent": 100
},
"completed_steps": [
{
"step": 1,
"name": "Implement query parser",
"description": "Added ParsedQuery struct and parse_search_query() helper to simple_index.rs"
},
{
"step": 2,
"name": "Integrate parser into search method",
"description": "Modified search() method to use parsed query for field-specific matching"
},
{
"step": 3,
"name": "Add tests for field filters",
"description": "Added 10 comprehensive unit tests for from:, to:, subject:, has:attachment parsing and matching"
}
],
"remaining_steps": [],
"working_data": {
"files_modified": [
"/home/ilyk/ai-projects/active/product/linux/mailapp/repo/core/src/search/simple_index.rs"
],
"files_checked_no_changes": [
"/home/ilyk/ai-projects/active/product/linux/mailapp/repo/asgard-mail/src/widgets/search_bar.rs"
]
},
"context_hints": {
"implementation": "Added field-specific prefix parsing on top of existing SearchQuery filtering",
"backward_compatibility": "Plain text queries without prefixes continue to work as before",
"build_status": "cargo build --lib -p asgard-core: SUCCESS"
},
"notes": "Implementation is complete and backward-compatible. Field-specific filters (from:, to:, subject:, has:attachment) can now be used in search queries."
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
{
"checkpoint_version": "1.0",
"task_id": "paned-resize-20260123-212800",
"agent": "dev-rust",
"task_description": "Fix paned resize behavior between middle (message list) and right (reader) panels",

"started_at": "2026-01-23T21:28:00Z",
"updated_at": "2026-01-23T21:45:00Z",
"status": "completed",

"progress": {
"current_phase": "completed",
"current_step": 6,
"total_steps": 6,
"percent_complete": 100
},

"completed_steps": [
{
"step": 1,
"name": "identify_issue",
"description": "User reported resize handle between center and right panels not working",
"result": "success",
"timestamp": "2026-01-23T21:28:00Z"
},
{
"step": 2,
"name": "fix_resize_config",
"description": "Changed resize_start_child to true, increased MESSAGE_LIST_MAX to 600",
"result": "success",
"timestamp": "2026-01-23T21:30:00Z"
},
{
"step": 3,
"name": "fix_overlap_issue",
"description": "Middle pane was covered by left pane - added hexpand to inner_paned, removed hexpand from reader",
"result": "success",
"timestamp": "2026-01-23T21:33:00Z"
},
{
"step": 4,
"name": "fix_sender_ellipsize",
"description": "Sender labels were preventing shrink - added ellipsize(End) to both sender labels",
"result": "success",
"timestamp": "2026-01-23T21:36:00Z"
},
{
"step": 5,
"name": "fix_slide_under",
"description": "Pane was sliding under sidebar - fixed by setting width_request on inner_paned = 200 + MESSAGE_VIEW_MIN (550px)",
"result": "success",
"timestamp": "2026-01-23T21:44:00Z"
},
{
"step": 6,
"name": "verify",
"description": "User confirmed resize works correctly",
"result": "success",
"timestamp": "2026-01-23T21:45:00Z"
}
],

"solution_summary": {
"problem": "Resize handle between message list and reader panel not working, panes overlapping and sliding under",
"root_causes": [
"resize_start_child was false - prevented handle dragging",
"sender labels missing ellipsize - forced minimum width too large",
"inner_paned had no width_request - allowed it to be squeezed causing slide-under"
],
"fixes_applied": [
"main.rs:2496-2497 - set resize_start_child(true) and resize_end_child(true)",
"main.rs:2498 - added hexpand(true) to inner_paned",
"main.rs:2500 - added width_request(200 + MESSAGE_VIEW_MIN) to inner_paned",
"main.rs:3593 - added ellipsize(End) to sender_label in message rows",
"main.rs:3732 - added ellipsize(End) to sender_label in sub-rows",
"main.rs:2483 - reduced messages_container width_request to 200"
]
}
}
36 changes: 36 additions & 0 deletions .agent/checkpoints/archive/secrets-cleanup-20260123-completed.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
"checkpoint_version": "1.0",
"task_id": "secrets-cleanup-20260123-214500",
"agent": "orchestrator",
"task_description": "Remove Google OAuth secrets from git history and move to secure config",

"started_at": "2026-01-23T21:45:00Z",
"updated_at": "2026-01-23T21:45:00Z",
"status": "in_progress",

"identity_reminder": "YOU ARE ORCHESTRATOR. DELEGATE.",

"progress": {
"current_phase": "planning",
"current_step": 1,
"total_steps": 4,
"percent_complete": 0
},

"pending_steps": [
{"step": 1, "name": "extract_secrets", "description": "Find and extract OAuth secrets from main.rs"},
{"step": 2, "name": "secure_storage", "description": "Move secrets to gitignored config file or env vars"},
{"step": 3, "name": "rewrite_history", "description": "Use git filter-repo to remove secrets from all commits"},
{"step": 4, "name": "force_push", "description": "Force push cleaned history to remote"}
],

"working_data": {
"affected_files": ["simple-gtk-app/src/main.rs"],
"secret_types": ["Google OAuth Client ID", "Google OAuth Client Secret"],
"affected_commits": ["e3d3581", "83e5993"],
"lines_with_secrets": [1247, 1248, 1341, 1342, 1456, 1457, 1554, 1555]
},

"recovery_instructions": "Check if secrets have been moved to config, check if git history has been rewritten",
"rollback_instructions": "Secrets are already in git history - no rollback needed for this cleanup"
}
7 changes: 7 additions & 0 deletions .agent/findings/KNOWN.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Known Findings Registry

**Check this file BEFORE reporting any finding as new.**

## Active Findings

<!-- None yet -->
117 changes: 117 additions & 0 deletions .agent/findings/P2-07-field-search-implementation.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,117 @@
# Implementation: Field-Specific Search Filters (P2-07)

**Completed**: 2026-02-17
**Task**: Support `from:`, `to:`, `subject:`, `has:attachment` prefixes in search queries

## Summary

Implemented field-specific search filter parsing on top of the SimpleSearchIndex to support advanced query syntax. Users can now search using:
- `from:user@example.com` - Filter by sender
- `to:user@example.com` - Filter by recipient
- `subject:keyword` - Filter by subject
- `has:attachment` or `has:attachments` - Filter messages with attachments
- Plain text terms (backward compatible)

## Implementation Details

### Files Modified
- `/home/ilyk/ai-projects/active/product/linux/mailapp/repo/core/src/search/simple_index.rs`

### Changes Made

1. **ParsedQuery struct** (lines 9-22)
- Data structure to hold parsed field-specific filters
- Fields: `terms`, `from_filter`, `to_filter`, `subject_filter`, `has_attachment`

2. **parse_search_query() function** (lines 24-60)
- Tokenizes query string by whitespace
- Strips recognized prefixes: `from:`, `to:`, `subject:`, `has:attachment`
- Collects remaining tokens as search terms
- Case-insensitive matching

3. **Modified search() method** (lines 167-285)
- Parses query at start using `parse_search_query()`
- Applies field-specific filters before general text search
- Handles `has:attachment` prefix as override to existing filter
- Maintains backward compatibility with plain text queries

### Design Decisions

1. **Field filters are exact/substring matches** - Uses `contains()` for flexible matching
- `from:alice` matches `alice@example.com`
- `subject:report` matches "Quarterly Report"

2. **Mixed queries work** - Can combine field filters with plain text
- `from:alice@example.com report` - Emails from Alice containing "report"
- `subject:meeting has:attachment` - Meetings with attachments

3. **Backward compatible** - Plain text queries unaffected
- Existing queries like `"hello world"` work as before

## Test Coverage

Added 10 comprehensive unit tests (lines 454-815):
1. `test_parse_search_query_plain_text` - Plain text parsing
2. `test_parse_search_query_from_filter` - from: prefix parsing
3. `test_parse_search_query_to_filter` - to: prefix parsing
4. `test_parse_search_query_subject_filter` - subject: prefix parsing
5. `test_parse_search_query_has_attachment` - has:attachment parsing
6. `test_parse_search_query_has_attachments` - has:attachments variant
7. `test_parse_search_query_mixed_filters` - Mixed filter queries
8. `test_search_with_from_filter` - from: filter matching
9. `test_search_with_from_filter_no_match` - from: filter no results
10. `test_search_with_subject_filter` - subject: filter matching
11. `test_search_with_to_filter` - to: filter matching
12. `test_search_with_has_attachment_filter` - has:attachment filter matching
13. `test_search_combined_filters` - Multiple filters together

## Build Status

```
cargo build --lib -p asgard-core: SUCCESS
```

No breaking changes. Build produces no errors related to search module.

## Files Checked (No Changes Needed)
- `/home/ilyk/ai-projects/active/product/linux/mailapp/repo/asgard-mail/src/widgets/search_bar.rs`
- Simply passes query string through to search layer
- No UI changes needed

## Usage Examples

```rust
// From Alice about "budget"
let query = SearchQuery {
query: "from:alice@example.com budget".to_string(),
..Default::default()
};

// Messages with attachments
let query = SearchQuery {
query: "has:attachment".to_string(),
..Default::default()
};

// Complex query
let query = SearchQuery {
query: "from:alice@example.com to:bob subject:report has:attachment".to_string(),
..Default::default()
};
```

## Performance Implications

- Query parsing: O(n) where n = number of whitespace-separated tokens (typically <10)
- Filter application: O(m) where m = number of indexed messages (existing)
- No additional memory overhead beyond ParsedQuery struct (~100 bytes)
- No database changes required

## Future Enhancements

Possible extensions (not implemented):
- `before:date` / `after:date` - Date range filtering
- `size:>1MB` - Attachment size filtering
- `is:flagged` / `is:unread` - State-based filtering (already supported via SearchQuery)
- Quoted phrases: `"exact phrase"`
- Negation: `-keyword` or `not:keyword`
66 changes: 66 additions & 0 deletions .agent/status.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
{
"updated_at": "2026-02-19T12:56:46.457582",
"orchestrator_pid": 3202884,
"active_agents": {
"fix-p3-01/p3-10-remaining-gaps": {
"type": "dev-rust",
"description": "Fix P3-01/P3-10 remaining gaps",
"prompt_preview": "Fix remaining gaps from three parallel agents that partially completed their work on Asgard Mail (GTK4/libadwaita Rust mail client). There are 3 things to fix:\n\n## 1. Register smart_mailbox module in ",
"started_at": "2026-02-17T15:38:35.176486",
"status": "running",
"tool_uses": 0
},
"p3-05:-offline-mode-implementa": {
"type": "dev-rust",
"description": "P3-05: Offline mode implementation",
"prompt_preview": "Implement Offline Mode (P3-05) for Asgard Mail, a GTK4/libadwaita Rust desktop mail client.\n\n## Goal\nQueue sends when offline using gio::NetworkMonitor, attempt delivery when connectivity is restored,",
"started_at": "2026-02-17T15:49:05.748517",
"status": "running",
"tool_uses": 0
},
"p3-02:-mail-rules-engine": {
"type": "dev-rust",
"description": "P3-02: Mail rules engine",
"prompt_preview": "Implement Mail Rules (P3-02) for Asgard Mail, a GTK4/libadwaita Rust desktop mail client.\n\n## Goal\nAdd auto-sort/auto-flag rules that run on incoming messages. Create a rules model, database table, an",
"started_at": "2026-02-17T15:52:57.261947",
"status": "running",
"tool_uses": 0
},
"validate-gap-closure-features": {
"type": "Explore",
"description": "Validate gap closure features",
"prompt_preview": "Thoroughly verify that all 30 features from the Asgard Mail Gap Closure Plan are implemented in the codebase at /home/ilyk/ai-projects/active/product/linux/mailapp/repo. Check for the presence of each",
"started_at": "2026-02-17T16:18:11.453099",
"status": "running",
"tool_uses": 0
},
"fix-21-test-compilation-errors": {
"type": "dev-rust",
"description": "Fix 21 test compilation errors",
"prompt_preview": "Fix all 21 test compilation errors in the asgard-core crate at `/home/ilyk/ai-projects/active/product/linux/mailapp/repo/core`.\n\nRun `cargo test -p asgard-core` first to see all errors. Then fix each ",
"started_at": "2026-02-19T12:53:37.716472",
"status": "running",
"tool_uses": 0
},
"update-project-docs": {
"type": "technical-writer",
"description": "Update project docs",
"prompt_preview": "Update 3 documentation files for the Asgard Mail project at `/home/ilyk/ai-projects/active/product/linux/mailapp`. The project just completed a massive \"Gap Closure Plan\" implementing ~30 features acr",
"started_at": "2026-02-19T12:53:43.032368",
"status": "running",
"tool_uses": 0
},
"document-stub-vs-wired-feature": {
"type": "Explore",
"description": "Document stub vs wired features",
"prompt_preview": "Analyze the Asgard Mail codebase at `/home/ilyk/ai-projects/active/product/linux/mailapp/repo` to determine which of the 30 gap closure features are fully wired vs UI-only stubs. \n\nFor each feature, c",
"started_at": "2026-02-19T12:54:36.967237",
"status": "running",
"tool_uses": 0
}
},
"completed_agents": [],
"current_activity": "Writing: 2026-02-19-gap-closure-feature-wiring-status.md",
"total_tool_uses": 567,
"session_start": "2026-02-17T14:18:44.041568"
}
Loading
Loading