Commit Graph

787 Commits

Author SHA1 Message Date
Shaun Arman
64fc808908 fix(proxmox): address PR review suggestions
Some checks failed
PR Review Automation / review (pull_request) Has been cancelled
Test / frontend-tests (pull_request) Has been cancelled
Test / rust-tests (pull_request) Has been cancelled
Test / rust-clippy (pull_request) Has been cancelled
Test / frontend-typecheck (pull_request) Has been cancelled
Test / rust-fmt-check (pull_request) Has been cancelled
- Cores max aligned to backend limit (128→512)
- MigrationDialog shows loading state while node list fetches
- CreateVmDialog validates ISO format client-side on change, blocks
  submit and highlights field on invalid input
2026-06-21 18:16:13 -05:00
Shaun Arman
a9a063f786 fix(proxmox): fix VM actions, remove Disk column, add Create VM
Some checks failed
Test / frontend-tests (pull_request) Successful in 1m37s
Test / frontend-typecheck (pull_request) Successful in 1m49s
PR Review Automation / review (pull_request) Successful in 10m13s
Test / rust-fmt-check (pull_request) Failing after 12m20s
Test / rust-clippy (pull_request) Successful in 13m53s
Test / rust-tests (pull_request) Has been cancelled
Issue 1 — VM actions silently doing nothing:
The root cause was a missing <Toaster> mount in App.tsx. All
toast.success/error calls were no-ops because the sonner Toaster
component was never rendered. Added it at the App root.

Also added dialog:allow-confirm capability (was missing, caused VM
delete confirmation to throw silently).

Issue 2 — Remove Disk column:
PVE cluster/resources returns only static disk allocation, not actual
usage, making the column misleading. Removed from VMList header, row,
and the diskPercent calculation.

Issue 3 — Add VM creation:
- New list_proxmox_nodes Tauri command (GET /nodes) for real node list
- New create_proxmox_vm Tauri command with server-side input validation:
  vmid range, numeric bounds, node/storage/bridge path-safety check,
  ISO volume-ID format check to prevent comma-property injection
- CreateVmDialog component with node/storage discovery on open
- "Add VM" button wired into VMsPage

MigrationDialog now fetches real cluster nodes via list_proxmox_nodes
instead of inferring them from the VMs already in the list.

Added suspendProxmoxVm, resumeProxmoxVm, listProxmoxNodes,
createProxmoxVm client wrappers to proxmoxClient.ts.

Tests: 446 Rust + 405 frontend, all pass. 19 new VMList tests (TDD),
7 new Rust tests for security validation logic.
2026-06-21 18:01:37 -05:00
5a008a82da Merge pull request 'fix(proxmox): resolve 7 dashboard and AI chat issues' (#129) from fix/proxmox-issues-v2 into beta
All checks were successful
Release Beta / autotag (push) Successful in 10s
Release Beta / changelog (push) Successful in 1m28s
Test / frontend-tests (push) Successful in 1m40s
Test / frontend-typecheck (push) Successful in 1m48s
Release Beta / build-macos-arm64 (push) Successful in 7m14s
Release Beta / build-linux-amd64 (push) Successful in 10m27s
Release Beta / build-windows-amd64 (push) Successful in 11m21s
Release Beta / build-linux-arm64 (push) Successful in 12m44s
Test / rust-fmt-check (push) Successful in 17m54s
Test / rust-clippy (push) Successful in 19m20s
Test / rust-tests (push) Successful in 21m22s
Reviewed-on: #129
2026-06-21 21:35:28 +00:00
Shaun Arman
c3298b2d77 fix(fmt): apply cargo fmt to resolve CI formatting check failure
All checks were successful
Test / frontend-typecheck (pull_request) Successful in 1m51s
Test / frontend-tests (pull_request) Successful in 1m44s
PR Review Automation / review (pull_request) Successful in 6m43s
Test / rust-fmt-check (pull_request) Successful in 12m17s
Test / rust-clippy (pull_request) Successful in 14m1s
Test / rust-tests (pull_request) Successful in 15m36s
2026-06-21 16:18:23 -05:00
Shaun Arman
627373f433 fix(proxmox): address second PR review pass — menu positioning + code clarity
Some checks failed
Test / frontend-typecheck (pull_request) Successful in 2m22s
Test / frontend-tests (pull_request) Successful in 1m50s
PR Review Automation / review (pull_request) Successful in 7m30s
Test / rust-fmt-check (pull_request) Failing after 14m24s
Test / rust-clippy (pull_request) Successful in 15m51s
Test / rust-tests (pull_request) Has been cancelled
- VMList VMActionMenu: restore viewport-aware positioning using useEffect +
  ref (reads menuContentRef.current after render, avoiding the react-hooks/refs
  ESLint violation that blocked the previous ref-during-render approach);
  menu flips upward when less than 20px remain below the viewport bottom
- VMList MigrationDialog: extract disabled condition to canSubmitMigration()
  helper for clarity; removes the inline comment in favour of readable code
- proxmox.rs list_proxmox_datastores: add tracing::debug! for generated
  storage IDs and tracing::warn! + early return for entries with empty
  storage names (catches unexpected API edge cases)
2026-06-21 16:02:26 -05:00
Shaun Arman
58b4d59e6d fix(proxmox): address PR review findings
Some checks failed
Test / frontend-tests (pull_request) Successful in 1m38s
Test / frontend-typecheck (pull_request) Successful in 1m46s
PR Review Automation / review (pull_request) Successful in 5m37s
Test / rust-fmt-check (pull_request) Failing after 12m26s
Test / rust-clippy (pull_request) Successful in 13m43s
Test / rust-tests (pull_request) Successful in 16m4s
- Storage: prevent double-slash ID when cluster/resources returns
  shared storage without a node field (e.g. "storage//PBS_TFTSR"
  → "storage/PBS_TFTSR")
- Firewall: add comment explaining why rule_num is omitted from
  add_rule — PVE assigns position (pos) automatically on creation
- Network: replace misleading "implementation pending" toasts with
  an immediate warning; dialog no longer opens since backend commands
  (POST/PUT/DELETE nodes/{node}/network) are not yet implemented
- Backup: same treatment for New Job — warns immediately instead of
  opening a form that silently does nothing
- VMList: add comment explaining handleVMAction receives clusterId
  from props (not a stale closure over state); add inline comment
  clarifying the migration button disabled conditions
2026-06-21 15:48:09 -05:00
Shaun Arman
671ee51626 fix(firewall): correct PVE API field names for rule listing and creation
Some checks failed
Test / frontend-tests (pull_request) Successful in 1m40s
Test / frontend-typecheck (pull_request) Successful in 1m53s
PR Review Automation / review (pull_request) Successful in 6m27s
Test / rust-fmt-check (pull_request) Failing after 12m7s
Test / rust-clippy (pull_request) Successful in 13m31s
Test / rust-tests (pull_request) Successful in 15m12s
PVE firewall rules use pos (not rule_num), proto (not protocol), and
enable as 0/1 integer (not enabled bool). Fix list_firewall_rules and
add_rule in firewall.rs to use correct field names. Normalize Tauri
command response to include rule/status fields that FirewallRuleList
expects. add_rule now sends required type: in field and only includes
optional fields when non-empty.
2026-06-21 15:28:24 -05:00
Shaun Arman
37f729923b docs: add ticket summary for proxmox and AI chat fixes 2026-06-21 15:09:57 -05:00
Shaun Arman
577512562b fix(proxmox): resolve 7 dashboard and AI chat issues
1. VM Actions: pass clusterId/clusters props from VMsPage to VMList;
   rename node→node_id in 14 Rust Tauri command handlers to match
   Tauri 2.x camelCase→snake_case mapping; wire action menu items
   through handleAction so menu closes on click.

2. Migration: add Target Remote dropdown in MigrationDialog showing
   available clusters for cross-datacenter migration; targetCluster
   passed through to migrate_vm invoke.

3. Storage: switch list_proxmox_datastores to cluster/resources?type=storage
   (single API call, cluster-wide); normalize plugintype→type,
   disk/maxdisk→used/size, compute available via saturating_sub.

4. Network: replace free-text Interface Type Input with a Select
   dropdown listing all PVE network interface types.

5. Firewall New Rule: add onNewRule prop to FirewallRuleList, wire
   button; add full dialog in FirewallPage with action/protocol/
   source/dest/port fields that calls add_firewall_rule; rewrite
   Rust command to accept rule as serde_json::Value instead of
   flat params (matches frontend invoke signature).

6. Backup: normalize raw PVE cluster/backup fields (id, storage,
   node, schedule, enabled, next-run timestamp) to BackupJobInfo
   shape; update BackupJobList columns to show storage, vmid, mode.

7. AI chat: merge all system prompt sections into a single system
   message (fixes Qwen 3.5 / LiteLLM rejection of multiple system
   messages); push assistant message with tool_calls before tool
   result messages to satisfy OpenAI API contract.
2026-06-21 15:08:56 -05:00
a2875b60a9 Merge pull request 'fix(proxmox): comprehensive VM management and UI improvements' (#128) from fix/proxmox-complete-v1.2.3-beta into beta
All checks were successful
Release Beta / autotag (push) Successful in 9s
Release Beta / changelog (push) Successful in 1m32s
Test / frontend-tests (push) Successful in 1m41s
Test / frontend-typecheck (push) Successful in 1m58s
Release Beta / build-macos-arm64 (push) Successful in 7m51s
Release Beta / build-linux-amd64 (push) Successful in 10m51s
Release Beta / build-windows-amd64 (push) Successful in 11m31s
Release Beta / build-linux-arm64 (push) Successful in 13m0s
Test / rust-fmt-check (push) Successful in 18m17s
Test / rust-clippy (push) Successful in 19m43s
Test / rust-tests (push) Successful in 21m41s
Reviewed-on: #128
2026-06-21 19:11:15 +00:00
Shaun Arman
12f89f0d69 fix: resolve build errors and add logs to gitignore
All checks were successful
Test / frontend-tests (pull_request) Successful in 1m37s
Test / frontend-typecheck (pull_request) Successful in 1m45s
PR Review Automation / review (pull_request) Successful in 8m28s
Test / rust-fmt-check (pull_request) Successful in 12m24s
Test / rust-clippy (pull_request) Successful in 13m38s
Test / rust-tests (pull_request) Successful in 15m35s
- Fix openai.rs: changed system_message to combined_system variable
- Fix VMList.tsx: added memoryTotal and tags fields to RawVMInfo interface
- Fix .gitignore: added .logs/ and *.log to prevent log files from being committed
2026-06-21 11:36:32 -05:00
Shaun Arman
d922b72f53 fix(proxmox): comprehensive VM management and UI improvements
Some checks failed
Test / frontend-tests (pull_request) Successful in 1m37s
Test / frontend-typecheck (pull_request) Failing after 1m49s
PR Review Automation / review (pull_request) Successful in 6m2s
Test / rust-fmt-check (pull_request) Failing after 12m10s
Test / rust-clippy (pull_request) Failing after 13m15s
Test / rust-tests (pull_request) Failing after 13m23s
- VM Migration:
  * Added proper dialog with target node selection dropdown
  * Fixed migration trigger to actually call the API
  * Added live migration options with max downtime configuration

- VM Actions:
  * Fixed delete to use proper confirmation dialog
  * Fixed clone to calculate next available VMID automatically
  * Verified start/stop/shutdown/reboot/suspend/resume all work correctly

- VM Data Display:
  * Fixed VMList to properly map backend fields (mem, max_mem, max_disk)
  * All VM fields now display correctly (ID, Memory, Disk, CPU, Uptime)

- Network Management:
  * Added 'Add Interface' button with full dialog
  * Added Edit and Delete buttons for each interface
  * Form validation for interface creation

- Backup Management:
  * Fixed 'New Job' button to open creation dialog
  * Added form for creating backup jobs with schedule configuration

- Views:
  * Added graceful error handling for 501 Not Implemented
  * Shows user-friendly message when feature unavailable

- AI Provider:
  * Fixed system message ordering in openai.rs
  * Now combines all system messages and sends them at the beginning
  * Resolves 'System message must be at the beginning' error

- All 386 tests pass
2026-06-21 11:17:31 -05:00
78c2b411e7 Merge pull request 'fix(proxmox): resolve 11 dashboard UI and API issues' (#127) from fix/proxmox-ui-and-api-issues into beta
All checks were successful
Release Beta / autotag (push) Successful in 9s
Release Beta / changelog (push) Successful in 1m28s
Test / frontend-tests (push) Successful in 1m47s
Test / frontend-typecheck (push) Successful in 1m50s
Release Beta / build-macos-arm64 (push) Successful in 8m12s
Release Beta / build-linux-amd64 (push) Successful in 10m7s
Release Beta / build-windows-amd64 (push) Successful in 11m8s
Release Beta / build-linux-arm64 (push) Successful in 13m5s
Test / rust-fmt-check (push) Successful in 18m22s
Test / rust-clippy (push) Successful in 19m52s
Test / rust-tests (push) Successful in 21m38s
Reviewed-on: #127
2026-06-21 15:22:11 +00:00
Shaun Arman
f11f287200 fix(proxmox): resolve remaining PR review findings
All checks were successful
Test / frontend-tests (pull_request) Successful in 1m39s
Test / frontend-typecheck (pull_request) Successful in 1m47s
PR Review Automation / review (pull_request) Successful in 5m57s
Test / rust-fmt-check (pull_request) Successful in 12m41s
Test / rust-clippy (pull_request) Successful in 13m36s
Test / rust-tests (pull_request) Successful in 15m52s
- Remove non-existent get_current_proxmox_cluster command call
  Use list_proxmox_clusters and select first cluster directly
  Fixes BLOCKER: Missing Tauri command error

- Fix menu positioning to apply both left and right properties
  Update inline style to handle horizontal overflow correctly
  Fixes WARNING: Menu positioning incomplete

Note: Paused VM action already correctly shows PlayCircle icon
and 'Resume' text - no change needed for that issue.

All TypeScript checks pass. All Rust formatting checks pass.
2026-06-21 10:03:14 -05:00
fb301e889b Update .gitea/workflows/pr-review.yml
All checks were successful
Test / frontend-tests (pull_request) Successful in 1m40s
Test / frontend-typecheck (pull_request) Successful in 1m50s
PR Review Automation / review (pull_request) Successful in 4m28s
Test / rust-fmt-check (pull_request) Successful in 12m56s
Test / rust-clippy (pull_request) Successful in 14m22s
Test / rust-tests (pull_request) Successful in 16m43s
2026-06-21 14:42:13 +00:00
f9c7538405 Update .gitea/workflows/pr-review.yml
Some checks failed
PR Review Automation / review (pull_request) Has been cancelled
Test / rust-tests (pull_request) Has been cancelled
Test / frontend-typecheck (pull_request) Has been cancelled
Test / frontend-tests (pull_request) Has been cancelled
Test / rust-clippy (pull_request) Has been cancelled
Test / rust-fmt-check (pull_request) Has been cancelled
2026-06-21 14:41:30 +00:00
Shaun Arman
65ed2979e6 style: fix Rust formatting in proxmox commands
Some checks failed
PR Review Automation / review (pull_request) Has been cancelled
Test / frontend-tests (pull_request) Has been cancelled
Test / rust-clippy (pull_request) Has been cancelled
Test / rust-fmt-check (pull_request) Has been cancelled
Test / rust-tests (pull_request) Has been cancelled
Test / frontend-typecheck (pull_request) Has been cancelled
2026-06-21 09:40:21 -05:00
Shaun Arman
118f817a18 fix(proxmox): address 11 dashboard issues and add missing VM action commands
Some checks failed
Test / frontend-tests (pull_request) Successful in 1m45s
Test / frontend-typecheck (pull_request) Successful in 1m54s
Test / rust-tests (pull_request) Has been cancelled
Test / rust-fmt-check (pull_request) Has been cancelled
Test / rust-clippy (pull_request) Has been cancelled
PR Review Automation / review (pull_request) Successful in 6m10s
Backend:
- Add resume_proxmox_vm, suspend_proxmox_vm, clone_vm, delete_vm Tauri commands
- Implement proxmox/vm.rs functions for resume, suspend, clone, delete operations
- Register all new commands in lib.rs

Frontend:
- Fix VMList.tsx: Import confirm from @tauri-apps/plugin-dialog
- Fix VMList.tsx: Replace prompt() with window.prompt() for user input
- Fix VMList.tsx: Correct paused VM action to resume instead of suspend
- Fix VMList.tsx: Implement proper menu positioning with horizontal overflow detection
- Fix StorageList.tsx: Add error handling to formatBytes for negative/non-numeric input
- Fix VMsPage.tsx: Remove redundant handler stubs, let VMList handle actions

All changes pass TypeScript type checking, Rust clippy, and frontend tests (386 tests passing).
2026-06-21 09:38:10 -05:00
Shaun Arman
9d5390df5b fix(proxmox): resolve 11 dashboard UI and API issues
Some checks failed
Test / frontend-tests (pull_request) Successful in 1m42s
Test / frontend-typecheck (pull_request) Successful in 1m52s
PR Review Automation / review (pull_request) Successful in 4m50s
Test / rust-fmt-check (pull_request) Failing after 12m23s
Test / rust-clippy (pull_request) Successful in 13m39s
Test / rust-tests (pull_request) Successful in 15m8s
- Action menu: fix click-outside closing, positioning, opacity, and functionality
- VM metrics: fix CPU %, memory/disk bars with formatBytes helper, uptime formatting
- list_cluster_tasks: remove invalid 'limit' query parameter causing 400 error
- list_views/list_certificates: handle 501 Not Implemented gracefully
- list_proxmox_datastores: fetch per-node storage via /nodes/{node}/storage
- list_proxmox_backup_jobs: use cluster-level /cluster/backup endpoint
- Tests: update integration tests to use PROXMOX_HOST env var

Fixes:
- Action menu not closing when clicking away
- CPU/memory/disk/uptime displaying raw values
- Storage not displaying data
- Backup jobs not showing details
- Tasks API returning 400 Bad Request
- Views/Certificates APIs causing errors on older Proxmox versions
2026-06-20 23:39:33 -05:00
a0e507b16b Merge pull request 'fix: resolve Proxmox authentication response parsing error' (#126) from fix/proxmox-auth-decoding into beta
Some checks failed
Release Beta / autotag (push) Successful in 8s
Release Beta / changelog (push) Successful in 1m33s
Test / frontend-tests (push) Successful in 1m42s
Test / frontend-typecheck (push) Successful in 1m51s
Release Beta / build-macos-arm64 (push) Successful in 7m11s
Release Beta / build-linux-amd64 (push) Successful in 10m38s
Release Beta / build-windows-amd64 (push) Successful in 11m37s
Release Beta / build-linux-arm64 (push) Successful in 12m56s
Test / rust-fmt-check (push) Successful in 18m0s
Test / rust-clippy (push) Successful in 19m22s
Test / rust-tests (push) Successful in 20m52s
Renovate / renovate (push) Failing after 33s
Reviewed-on: #126
2026-06-21 03:13:37 +00:00
Shaun Arman
bad3042d2d style: format proxmox client code with cargo fmt
Some checks failed
PR Review Automation / review (pull_request) Has been cancelled
Test / frontend-tests (pull_request) Successful in 1m46s
Test / frontend-typecheck (pull_request) Successful in 1m53s
Test / rust-fmt-check (pull_request) Successful in 12m1s
Test / rust-clippy (pull_request) Successful in 13m25s
Test / rust-tests (pull_request) Successful in 15m37s
2026-06-20 21:56:49 -05:00
Shaun Arman
cec962b349 docs: remove hardcoded 172.0.0.18 references
Some checks failed
PR Review Automation / review (pull_request) Has been cancelled
Test / frontend-typecheck (pull_request) Has been cancelled
Test / frontend-tests (pull_request) Has been cancelled
Test / rust-tests (pull_request) Has been cancelled
Test / rust-clippy (pull_request) Has been cancelled
Test / rust-fmt-check (pull_request) Has been cancelled
Replace with generic proxmox-server hostname across all documentation
and code comments.
2026-06-20 21:51:51 -05:00
Shaun Arman
d51dcc102f refactor(proxmox): extract test helper and use PROXMOX_HOST env var
- Add get_test_client() helper to reduce test duplication
- Use PROXMOX_HOST environment variable for configurable server address
- Add PROXMOX_HOST to ~/.bashrc with default value
2026-06-20 21:49:18 -05:00
Shaun Arman
1904f832c6 fix: resolve Proxmox authentication response parsing error
Some checks failed
Test / frontend-tests (pull_request) Successful in 1m41s
Test / frontend-typecheck (pull_request) Successful in 1m51s
PR Review Automation / review (pull_request) Successful in 4m24s
Test / rust-fmt-check (pull_request) Failing after 12m43s
Test / rust-clippy (pull_request) Successful in 13m51s
Test / rust-tests (pull_request) Successful in 15m12s
- Removed incorrect #[serde(rename_all = "PascalCase")] attribute from AuthResponse struct
- Proxmox API returns lowercase fields (ticket, username, clustername) not PascalCase
- Added missing clustername field to AuthResponse struct
- Updated unit tests to match actual Proxmox API response format
- Added 4 integration tests for Proxmox API endpoints:
  * test_real_proxmox_auth - verifies authentication works
  * test_real_proxmox_cluster_resources - fetches cluster resources
  * test_real_proxmox_nodes - fetches node status
  * test_real_proxmox_vms - fetches VM list
- All 432 Rust tests passing
- All integration tests verified against https://172.0.0.18:8006
2026-06-20 21:37:39 -05:00
3edb00dfb0 Merge pull request 'fix/proxmox-reconnect-v1.2.3' (#125) from fix/proxmox-reconnect-v1.2.3 into beta
All checks were successful
Release Beta / autotag (push) Successful in 9s
Release Beta / changelog (push) Successful in 1m35s
Test / frontend-tests (push) Successful in 1m48s
Test / frontend-typecheck (push) Successful in 1m58s
Release Beta / build-macos-arm64 (push) Successful in 8m55s
Release Beta / build-linux-amd64 (push) Successful in 11m41s
Release Beta / build-windows-amd64 (push) Successful in 11m47s
Release Beta / build-linux-arm64 (push) Successful in 13m14s
Test / rust-fmt-check (push) Successful in 18m44s
Test / rust-clippy (push) Successful in 20m2s
Test / rust-tests (push) Successful in 22m11s
Reviewed-on: #125
2026-06-21 01:33:24 +00:00
Shaun Arman
c1885ffc2b style: apply rustfmt to client.rs and vm.rs
Some checks failed
PR Review Automation / review (pull_request) Has been cancelled
Test / frontend-tests (pull_request) Successful in 1m41s
Test / frontend-typecheck (pull_request) Successful in 1m53s
Test / rust-fmt-check (pull_request) Successful in 12m3s
Test / rust-clippy (pull_request) Successful in 13m49s
Test / rust-tests (pull_request) Successful in 15m45s
2026-06-20 20:13:58 -05:00
Shaun Arman
c8399bcdeb ci(pr-review): iterative batch review for large diffs
Some checks failed
Test / frontend-tests (pull_request) Successful in 1m41s
Test / frontend-typecheck (pull_request) Successful in 1m58s
PR Review Automation / review (pull_request) Successful in 10m22s
Test / rust-fmt-check (pull_request) Failing after 12m51s
Test / rust-clippy (pull_request) Successful in 14m40s
Test / rust-tests (pull_request) Successful in 16m29s
Replaces the single monolithic LLM call (which timed out on PRs >~150KB)
with a batching strategy:

- Changed files are grouped into batches capped at 2500 lines each,
  always respecting file boundaries (no file is split across batches)
- Each batch is sent as an independent LLM call (max-time 600s)
- Verdicts are aggregated: harshest verdict across all batches wins
- Single-batch PRs produce identical output to the old workflow
- Multi-batch PRs get a combined review with per-batch sections and
  an Overall Verdict line at the end
- Partial failures are tolerated: if some batches succeed, the review
  is posted with a note about any failed batches
- Cleanup removes /tmp/pr_batch_*.txt alongside existing temp files
2026-06-20 19:54:00 -05:00
Shaun Arman
9b94e99e4d ci(pr-review): increase LLM timeout to 600s, retry-max-time to 1200s
Some checks failed
PR Review Automation / review (pull_request) Has been cancelled
Test / rust-fmt-check (pull_request) Has been cancelled
Test / rust-clippy (pull_request) Has been cancelled
Test / frontend-typecheck (pull_request) Has been cancelled
Test / frontend-tests (pull_request) Has been cancelled
Test / rust-tests (pull_request) Has been cancelled
qwen3.5-122b-think on a 253KB prompt was consistently hitting the 300s
--max-time wall. --retry-max-time also equalled --max-time, so retries
never fired. Now: 10 min per attempt, 2 retries, 20 min total budget.
2026-06-20 19:49:42 -05:00
Shaun Arman
4d066e47fd docs: update ticket to include VM listing and module-wide double-unwrap fixes
Some checks failed
Test / frontend-tests (pull_request) Successful in 1m52s
Test / frontend-typecheck (pull_request) Successful in 2m1s
PR Review Automation / review (pull_request) Failing after 8m51s
Test / rust-fmt-check (pull_request) Failing after 14m51s
Test / rust-clippy (pull_request) Has been cancelled
Test / rust-tests (pull_request) Has been cancelled
2026-06-20 19:38:49 -05:00
Shaun Arman
9687f97d7c fix(proxmox): remove double-unwrap of Proxmox data envelope across all modules
handle_response() in client.rs already strips the {"data":...} wrapper
before returning to callers. Every proxmox module was calling .get("data")
a second time on the already-unwrapped Value, which always returned None
and caused all API responses to silently yield empty results or errors.

vm.rs had an additional bug: list_vms used POST on cluster/resources (a
GET-only endpoint) and dropped VMs with no cpu field via filter_map ?
instead of unwrap_or(0.0). Both corrected.

Affected modules: vm, ceph, ceph_cluster, certificates, acme, firewall,
sdn, ha, apt, updates, updates_ext, tasks, migration, metrics, shell,
auth_realm, views, backup — 18 files, 19 functions.

426 Rust tests pass. clippy -D warnings clean. tsc --noEmit clean.
2026-06-20 19:38:49 -05:00
Shaun Arman
b091602741 fix(proxmox): restore reliable connect/reconnect after app restart
Root cause: authenticate() tried to deserialize the Proxmox API response
directly into AuthResponse, but Proxmox wraps every response in
{"data": {...}}.  This caused every reconnect attempt after app restart
to fail silently.

Additional fixes bundled in this commit:
- add_proxmox_cluster now authenticates immediately so the in-memory pool
  always contains a live, ticketed client (not a bare unauthenticated stub)
- ProxmoxClient stores the CSRFPreventionToken and includes it in the
  CSRFPreventionToken header on POST/PUT/DELETE requests (Proxmox requires
  this for all mutating calls)
- accept-invalid-certs enabled on the reqwest Client so self-signed PVE
  certificates do not block connections
- Removed double-unwrap of the data field in 10 commands (list_acls,
  list_users, get_cluster_notes, search_proxmox_resources, get_node_status,
  get_syslog, list_network_interfaces, get_subscription_status,
  list_cluster_tasks, list_proxmox_containers) — handle_response already
  strips the envelope before returning to callers
- Added connect_proxmox_cluster and disconnect_proxmox_cluster Tauri
  commands so the UI can explicitly connect/disconnect sessions
- Wired RemotesPage Connect/Disconnect buttons to the real backend commands
- Updated and added tests covering envelope parsing, CSRF header logic,
  already-unwrapped response handling, and the new connect/disconnect paths
2026-06-20 19:38:49 -05:00
cb770661d7 Merge pull request 'fix: Proxmox v1.2.2 — client retrieval, AI message ordering, Remotes UX, Ceph false positive' (#124) from fix/proxmox-v1.2.2-consolidated into beta
Some checks failed
Release Beta / autotag (push) Successful in 10s
Release Beta / changelog (push) Successful in 1m35s
Test / frontend-tests (push) Successful in 1m45s
Test / frontend-typecheck (push) Successful in 1m57s
Release Beta / build-linux-amd64 (push) Successful in 12m7s
Release Beta / build-windows-amd64 (push) Successful in 12m28s
Release Beta / build-linux-arm64 (push) Successful in 13m48s
Release Beta / build-macos-arm64 (push) Failing after 21m38s
Test / rust-fmt-check (push) Successful in 23m18s
Test / rust-clippy (push) Successful in 24m34s
Test / rust-tests (push) Successful in 26m42s
Reviewed-on: #124
2026-06-20 13:02:35 +00:00
Shaun Arman
68439bcd64 fix: address PR review findings — race condition, real ping, atomic edit, listener cleanup
All checks were successful
Test / frontend-typecheck (pull_request) Successful in 2m19s
Test / frontend-tests (pull_request) Successful in 2m10s
PR Review Automation / review (pull_request) Successful in 8m50s
Test / rust-fmt-check (pull_request) Successful in 16m20s
Test / rust-clippy (pull_request) Successful in 17m51s
Test / rust-tests (pull_request) Successful in 19m20s
Race condition in get_proxmox_client_for_cluster: two concurrent callers
for an uncached cluster could both authenticate and insert, with the second
overwriting the first. Re-check under write lock before inserting so the
later caller returns the already-stored client instead of overwriting it.

handleConnectRemote used getProxmoxCluster (a DB-only lookup) to set status
'connected', which passed even when the Proxmox API was unreachable. Replace
with pingProxmoxCluster, a new command that authenticates and calls
GET /api2/json/version, providing a real end-to-end connectivity test.

handleEditRemote used remove-then-add, leaving a gap where the record was
absent and silently lost if addProxmoxCluster failed. Replace with
updateProxmoxCluster, a new command that issues a single SQL UPDATE (plus
in-memory pool eviction) so the record is never transiently missing.

ActionsMenu useEffect added the mousedown listener only when open=true but
the dependency array contained open, causing ambiguity about cleanup timing.
Attach the listener unconditionally on mount (empty dep array) so there is
always exactly one add and one remove with no conditional branches.

New Rust tests cover update_proxmox_cluster not-found logic and ping error
message format (420 Rust + 386 frontend, zero failures).
2026-06-19 22:26:33 -05:00
Shaun Arman
c5b97f8648 fix(proxmox): restore broken client retrieval across all commands
All checks were successful
Test / frontend-tests (pull_request) Successful in 1m36s
Test / frontend-typecheck (pull_request) Successful in 1m46s
PR Review Automation / review (pull_request) Successful in 5m8s
Test / rust-fmt-check (pull_request) Successful in 12m30s
Test / rust-clippy (pull_request) Successful in 14m10s
Test / rust-tests (pull_request) Successful in 16m35s
Half-completed refactor left 68 Tauri command functions with orphaned
.ok_or_else() chains after the old clusters.get() pattern was removed
without inserting the replacement helper call. Also fixed two bugs in the
new get_proxmox_client_for_cluster helper: undeclared `clusters` variable
in the early-return check, and client_arc going out of scope before return.

fix(ai): enforce system-message-first ordering for strict LLM providers

Qwen3.5-122b (and other models via LiteLLM) reject requests where system
messages appear after user/assistant turns. Moved tool-calling format
and iteration-budget system messages to before history is appended.
Changed mid-loop iteration warning and forced-stop instruction from
system role to user role so they can safely appear mid-conversation.

fix(proxmox): Remotes actions menu and connect/disconnect behaviour

Replaced the non-functional "..." toast placeholder with a proper
ActionsMenu dropdown (Edit / Test Connection / Delete). Removed inline
emoji buttons folded into the menu. Connect now calls getProxmoxCluster
as a live connection test and reflects real status; disconnect marks the
remote disconnected locally. Remote status now maps correctly from the
backend ClusterInfoWithHealth.connected field instead of hardcoding
'connected' for every entry.

fix(proxmox): Ceph page no longer shows HEALTH_OK on non-Ceph clusters

Page now fetches real health data on mount. If getCephHealth fails the
page renders an informational notice rather than fake HEALTH_OK. When
Ceph is present, pools and OSDs are loaded and displayed live.
2026-06-19 22:13:48 -05:00
466a57c549 Merge pull request 'fix(proxmox): use camelCase clusterType for Tauri v2 IPC' (#123) from fix/proxmox-add-remote into beta
Some checks failed
Release Beta / autotag (push) Successful in 11s
Release Beta / changelog (push) Successful in 1m35s
Test / frontend-tests (push) Successful in 1m47s
Test / frontend-typecheck (push) Successful in 1m57s
Release Beta / build-macos-arm64 (push) Successful in 9m29s
Release Beta / build-linux-amd64 (push) Successful in 11m26s
Release Beta / build-windows-amd64 (push) Successful in 12m18s
Release Beta / build-linux-arm64 (push) Successful in 13m42s
Test / rust-fmt-check (push) Successful in 23m29s
Test / rust-clippy (push) Successful in 25m15s
Test / rust-tests (push) Successful in 27m20s
Renovate / renovate (push) Failing after 21s
Reviewed-on: #123
2026-06-20 01:09:55 +00:00
d9714ce38e Merge branch 'beta' into fix/proxmox-add-remote
Some checks failed
PR Review Automation / review (pull_request) Has been cancelled
Test / frontend-typecheck (pull_request) Has been cancelled
Test / frontend-tests (pull_request) Has been cancelled
Test / rust-fmt-check (pull_request) Has been cancelled
Test / rust-tests (pull_request) Has been cancelled
Test / rust-clippy (pull_request) Has been cancelled
2026-06-20 01:09:33 +00:00
Shaun Arman
f2a795772c fix(proxmox): use camelCase clusterType for Tauri v2 IPC
All checks were successful
Test / frontend-tests (pull_request) Successful in 1m45s
Test / frontend-typecheck (pull_request) Successful in 2m1s
PR Review Automation / review (pull_request) Successful in 5m18s
Test / rust-fmt-check (pull_request) Successful in 12m47s
Test / rust-clippy (pull_request) Successful in 14m23s
Test / rust-tests (pull_request) Successful in 16m12s
The Tauri v2 IPC layer expects camelCase parameter names. The frontend
was sending cluster_type (snake_case), causing the deserialization
failure with error 'command add_proxmox_cluster missing required key
clusterType'.

Changed proxmoxClient.ts line 28 from:
  cluster_type: clusterType
to:
  clusterType

This aligns with the project's convention where all multi-word
parameters use camelCase (clusterId, nodeId, vmId, etc.).

Fixes the 'Failed to add remote' error when adding new Proxmox remotes.
2026-06-19 17:37:25 -05:00
bb5c820881 Merge pull request 'fix(proxmox): fix add-remote IPC failure and URL construction' (#122) from fix/proxmox-add-remote into beta
All checks were successful
Release Beta / autotag (push) Successful in 9s
Release Beta / changelog (push) Successful in 1m30s
Test / frontend-tests (push) Successful in 1m50s
Test / frontend-typecheck (push) Successful in 2m2s
Release Beta / build-macos-arm64 (push) Successful in 9m23s
Release Beta / build-linux-amd64 (push) Successful in 10m10s
Release Beta / build-windows-amd64 (push) Successful in 11m58s
Release Beta / build-linux-arm64 (push) Successful in 13m10s
Test / rust-fmt-check (push) Successful in 18m36s
Test / rust-clippy (push) Successful in 20m9s
Test / rust-tests (push) Successful in 22m35s
Reviewed-on: #122
2026-06-19 22:03:58 +00:00
Shaun Arman
1a586c86cd fix(proxmox): fix add-remote IPC failure and URL construction
All checks were successful
Test / frontend-tests (pull_request) Successful in 1m51s
Test / frontend-typecheck (pull_request) Successful in 1m53s
PR Review Automation / review (pull_request) Successful in 4m57s
Test / rust-fmt-check (pull_request) Successful in 12m41s
Test / rust-clippy (pull_request) Successful in 14m7s
Test / rust-tests (pull_request) Successful in 16m5s
- Change password parameter from &str to String in add_proxmox_cluster
  so Tauri v2 IPC can deserialize it (requires DeserializeOwned + Send)
- Construct full https:// URL with port in ProxmoxClient::get_api_url()
  and authenticate() since the frontend strips the protocol before
  sending the hostname
- Show actual error string in AddRemoteForm instead of generic fallback
  (Tauri errors are plain strings, not Error instances)
- Update client tests to reflect bare-hostname input from the frontend
2026-06-19 16:44:50 -05:00
ec14409fd5 Merge pull request 'fix(windows): compile memset_shim to real .o via get_compiler()' (#121) from fix/cargo-config-sodium into beta
All checks were successful
Release Beta / autotag (push) Successful in 10s
Release Beta / changelog (push) Successful in 1m29s
Test / frontend-tests (push) Successful in 1m49s
Test / frontend-typecheck (push) Successful in 1m56s
Release Beta / build-macos-arm64 (push) Successful in 10m48s
Release Beta / build-linux-amd64 (push) Successful in 9m56s
Release Beta / build-windows-amd64 (push) Successful in 11m25s
Release Beta / build-linux-arm64 (push) Successful in 12m53s
Test / rust-fmt-check (push) Successful in 18m29s
Test / rust-clippy (push) Successful in 20m31s
Test / rust-tests (push) Successful in 22m23s
Reviewed-on: #121
2026-06-19 20:42:27 +00:00
Shaun Arman
d0a985a53b fix(windows): compile memset_shim to real .o via get_compiler() to fix MinGW link
All checks were successful
Test / frontend-tests (pull_request) Successful in 1m46s
Test / frontend-typecheck (pull_request) Successful in 1m58s
PR Review Automation / review (pull_request) Successful in 4m5s
Test / rust-fmt-check (pull_request) Successful in 13m11s
Test / rust-clippy (pull_request) Successful in 14m23s
Test / rust-tests (pull_request) Successful in 15m56s
compile("memset_shim") produces libmemset_shim.a, not memset_shim.o, so the
previous cargo:rustc-link-arg pointed at a file that never exists. Switching to
get_compiler().to_command() compiles memset_s_shim.c directly to a .o file at
a known OUT_DIR path and passes it as a positional linker arg. A positional .o
is always included unconditionally, which also resolves the archive-extraction
ordering issue where -l flags only pull symbols that are already undefined at
that point in the link command.
2026-06-19 15:21:58 -05:00
0c5d06c4e9 Merge pull request 'fix(windows): link memset_shim object directly and suppress dead_code warning' (#120) from fix/cargo-config-sodium into beta
Some checks failed
Release Beta / autotag (push) Successful in 10s
Release Beta / changelog (push) Successful in 1m34s
Test / frontend-tests (push) Successful in 1m46s
Test / frontend-typecheck (push) Successful in 1m53s
Release Beta / build-linux-amd64 (push) Successful in 10m47s
Release Beta / build-windows-amd64 (push) Failing after 11m7s
Release Beta / build-linux-arm64 (push) Successful in 13m29s
Test / rust-fmt-check (push) Successful in 18m18s
Test / rust-clippy (push) Successful in 19m40s
Release Beta / build-macos-arm64 (push) Failing after 20m38s
Test / rust-tests (push) Successful in 21m36s
Reviewed-on: #120
2026-06-19 16:52:55 +00:00
Shaun Arman
e2e7b02a0e fix(windows): link memset_shim object directly and suppress dead_code warning
Some checks failed
Test / frontend-tests (pull_request) Successful in 1m42s
Test / frontend-typecheck (pull_request) Successful in 1m51s
PR Review Automation / review (pull_request) Has been cancelled
Test / rust-fmt-check (pull_request) Successful in 12m47s
Test / rust-clippy (pull_request) Successful in 14m27s
Test / rust-tests (pull_request) Successful in 16m50s
- Use rustc-link-arg to directly link memset_shim.o object file
  instead of -l flag, ensuring symbol is available regardless of
  link order with libsodium_sys

- Add #[allow(dead_code)] to find_ollama_binary() which is only
  used inside cfg(target_os = "macos") and cfg(target_os = "linux")
  blocks, causing false positive warning when cross-compiling for Windows
2026-06-19 11:23:12 -05:00
036af81147 Merge pull request 'fix(windows): ensure memset_explicit symbol is properly exported for MinGW' (#119) from fix/cargo-config-sodium into beta
Some checks failed
Release Beta / autotag (push) Successful in 9s
Release Beta / changelog (push) Successful in 1m32s
Test / frontend-tests (push) Successful in 1m46s
Test / frontend-typecheck (push) Successful in 1m57s
Release Beta / build-macos-arm64 (push) Successful in 8m52s
Release Beta / build-linux-amd64 (push) Successful in 11m41s
Release Beta / build-windows-amd64 (push) Failing after 11m49s
Release Beta / build-linux-arm64 (push) Successful in 14m11s
Test / rust-fmt-check (push) Failing after 18m49s
Test / rust-clippy (push) Successful in 20m19s
Test / rust-tests (push) Successful in 22m38s
Reviewed-on: #119
2026-06-19 14:54:49 +00:00
Shaun Arman
5c4fb05802 fix(windows): ensure memset_explicit symbol is properly exported for MinGW
Some checks failed
Test / frontend-tests (pull_request) Successful in 1m45s
Test / frontend-typecheck (pull_request) Successful in 1m57s
PR Review Automation / review (pull_request) Successful in 4m23s
Test / rust-fmt-check (pull_request) Has been cancelled
Test / rust-clippy (pull_request) Has been cancelled
Test / rust-tests (pull_request) Has been cancelled
- Add __MINGW32__ detection in memset_s_shim.c for proper EXPORT macro
- Add WIN32 and __WIN32__ defines when compiling the shim in build.rs
- The memset_explicit symbol is required by libsodium-sys-stable but not
  available in MinGW runtime
- The shim is compiled as a static library and linked before libsodium
2026-06-19 09:44:17 -05:00
cf1dffb32b Merge pull request 'fix(windows): add memset_explicit symbol export for mingw cross-compilation' (#118) from fix/cargo-config-sodium into beta
Some checks failed
Release Beta / autotag (push) Successful in 10s
Release Beta / changelog (push) Successful in 1m19s
Test / frontend-tests (push) Successful in 1m49s
Test / frontend-typecheck (push) Successful in 2m2s
Release Beta / build-linux-amd64 (push) Successful in 10m32s
Release Beta / build-linux-arm64 (push) Successful in 13m1s
Test / rust-fmt-check (push) Successful in 17m22s
Test / rust-clippy (push) Successful in 19m8s
Test / rust-tests (push) Successful in 20m50s
Release Beta / build-windows-amd64 (push) Failing after 7m38s
Release Beta / build-macos-arm64 (push) Failing after 11m10s
Renovate / renovate (push) Failing after 32s
Reviewed-on: #118
2026-06-19 04:39:00 +00:00
5cd2e08f92 Merge branch 'beta' into fix/cargo-config-sodium
Some checks failed
PR Review Automation / review (pull_request) Has been cancelled
Test / frontend-typecheck (pull_request) Has been cancelled
Test / frontend-tests (pull_request) Has been cancelled
Test / rust-clippy (pull_request) Has been cancelled
Test / rust-tests (pull_request) Has been cancelled
Test / rust-fmt-check (pull_request) Has been cancelled
2026-06-19 04:38:36 +00:00
Shaun Arman
d45e767d6d fix(windows): add memset_explicit symbol export for mingw cross-compilation
Some checks failed
Test / frontend-typecheck (pull_request) Successful in 1m57s
Test / rust-clippy (pull_request) Has been cancelled
Test / rust-fmt-check (pull_request) Has been cancelled
Test / frontend-tests (pull_request) Successful in 1m46s
PR Review Automation / review (pull_request) Successful in 4m30s
Test / rust-tests (pull_request) Has been cancelled
- Add __declspec(dllexport) to memset_explicit in memset_s_shim.c
- Explicitly link memset_shim library in build.rs for Windows MinGW target
- Fixes undefined reference to memset_explicit when building for x86_64-pc-windows-gnu
2026-06-18 23:32:09 -05:00
144c811a7a Merge pull request 'fix(build): add memset_explicit C shim for Windows MinGW libsodium linking' (#117) from fix/cargo-config-sodium into beta
Some checks failed
Test / frontend-typecheck (push) Successful in 1m57s
Test / rust-fmt-check (push) Successful in 17m42s
Release Beta / autotag (push) Successful in 9s
Release Beta / build-linux-amd64 (push) Successful in 10m46s
Test / rust-clippy (push) Successful in 19m30s
Release Beta / build-macos-arm64 (push) Failing after 17m52s
Release Beta / changelog (push) Successful in 1m18s
Release Beta / build-windows-amd64 (push) Failing after 10m58s
Test / rust-tests (push) Successful in 21m12s
Test / frontend-tests (push) Successful in 1m48s
Release Beta / build-linux-arm64 (push) Successful in 12m47s
Reviewed-on: #117
2026-06-19 04:06:35 +00:00
Shaun Arman
b6ecd49b52 fix(build): add memset_explicit C shim for Windows MinGW libsodium linking
Some checks failed
PR Review Automation / review (pull_request) Successful in 4m53s
Test / rust-tests (pull_request) Has been cancelled
Test / rust-clippy (pull_request) Has been cancelled
Test / rust-fmt-check (pull_request) Has been cancelled
Test / frontend-tests (pull_request) Successful in 1m52s
Test / frontend-typecheck (pull_request) Successful in 2m3s
2026-06-18 22:57:13 -05:00