-
Notifications
You must be signed in to change notification settings - Fork 594
Bug: Fix build issues #503
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…proved security and functionality
- Added `tauri-plugin-process` to Cargo.toml and initialized it in main.rs. - Updated migrated.json to include process permissions. - Introduced health check endpoints for main backend and sync microservice. - Created ServerCheck component to verify the health of services during onboarding. - Enhanced InfoDialog to conditionally show close button based on state. - Updated settings page to streamline user preferences query. - Added CORS middleware to sync microservice for cross-origin requests. - Refactored API functions to include health check logic.
…nd tauri.conf.json
WalkthroughThis PR replaces custom backend logging with default Uvicorn logging, renames the health endpoint to /health, updates Tauri packaging (resources, plugins, capabilities), adds sync microservice integration, introduces health-check onboarding, adds user preferences APIs/UI, bumps versions, and adjusts routes and settings. Minor CI/ignore/file-path changes included. Changes
Sequence Diagram(s)sequenceDiagram
autonumber
actor User
participant App as Tauri App
participant Onboard as Onboarding:ServerCheck
participant BE as Backend (/health)
participant Sync as Sync Microservice (/health)
Note over App: App startup
App->>Onboard: Start ServerCheck(stepIndex)
Onboard->>App: Dispatch showLoader("Waiting for servers to start")
par Parallel health checks
Onboard->>BE: GET /health
Onboard->>Sync: GET /health
end
alt Any failure
BE-->>Onboard: Error OR
Sync-->>Onboard: Error
Onboard->>App: Dispatch showInfoDialog(title="Error", message="Failed to connect...", showCloseButton=false)
Note over App: Exit after 2s
App-->>User: Application exits
else Both succeed
BE-->>Onboard: 200 OK
Sync-->>Onboard: 200 OK
Onboard->>App: Dispatch hideLoader()
Onboard->>App: Dispatch markCompleted(stepIndex)
App-->>User: Continue onboarding
end
Estimated code review effort🎯 4 (Complex) | ⏱️ ~60 minutes Possibly related PRs
Poem
Warning Review ran into problems🔥 ProblemsGit: Failed to clone repository. Please run the ✨ Finishing Touches
🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
… configuration files
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (3)
backend/app/utils/microservice.py (2)
79-85: Avoid PIPE deadlock; don’t capture child stdout/stderr unless consumed.
stdout=PIPE, stderr=PIPEwith no readers can block the parent if the child emits enough output. Redirect instead.- process = subprocess.Popen( - [str(sync_executable)], - stdout=subprocess.PIPE, - stderr=subprocess.PIPE, - text=True, - cwd=str(sync_dir), # Set working directory to sync service directory - ) + process = subprocess.Popen( + [str(sync_executable)], + stdout=subprocess.DEVNULL, + stderr=subprocess.STDOUT, + cwd=str(sync_dir), + )
234-241: backend/app/utils/microservice.py (lines 234–241): remove stray print and fix dev startupReplace the existing dev‐server invocation with a uvicorn command (drops the unnecessary debug print):
- print(python_executable) - cmd = [str(python_executable), "-m", "fastapi", "dev", "--port", "8001"] + cmd = [ + str(python_executable), + "-m", + "uvicorn", + "main:app", + "--host", + "127.0.0.1", + "--port", + "8001", + "--reload", + ]frontend/src/App.tsx (1)
3-3: Fix import: BrowserRouter must come from react-router-domThis is likely a build break.
-import { BrowserRouter } from 'react-router'; +import { BrowserRouter } from 'react-router-dom';
🧹 Nitpick comments (30)
sync-microservice/.gitignore (1)
139-140: Ensure dist placeholder exists for clean clones/buildsGood switch to ignore dist contents while tracking a placeholder. Make sure dist/README.md is actually committed; otherwise CI packaging that expects the directory may fail on clean checkouts.
#!/bin/bash set -euo pipefail for d in backend sync-microservice; do if [[ -f "$d/dist/README.md" ]]; then echo "OK: $d/dist/README.md present" else echo "MISSING: $d/dist/README.md" >&2 exit 1 fi donePrefer a neutral placeholder file name (e.g., .gitkeep) to avoid bundling docs unintentionally into installers.
frontend/src/constants/steps.ts (1)
2-2: Type-safety: mark STEPS as constExporting literal types helps prevent typos downstream.
-export const STEPS = { +export const STEPS = { SERVER_CHECK: 'serverCheck', AVATAR_SELECTION_STEP: 'avatarSelection', FOLDER_SETUP_STEP: 'folderSetup', THEME_SELECTION_STEP: 'themeSelection', UPDATE_STEP: 'updates', -}; +} as const; +export type StepName = typeof STEPS[keyof typeof STEPS];backend/.gitignore (1)
139-140: Mirror placeholder check for backend/distSame note as sync-microservice: verify dist/README.md is committed so packaging doesn’t break on a clean workspace.
#!/bin/bash test -f backend/dist/README.md && echo "backend/dist/README.md OK" || { echo "Missing backend/dist/README.md"; exit 1; }Consider using a .gitkeep instead of README if the file is only to keep the directory.
frontend/src-tauri/Cargo.toml (1)
3-3: Cargo.toml polish + compatibility check
- Typo in the comment (“definition s”).
- Confirm tauri = 2.3.1 actually requires/enables the "devtools" crate feature; in Tauri v2, devtools are usually toggled via tauri.conf.json.
- Versions: Rust tauri-plugin-process = "2.0.0" vs JS @tauri-apps/plugin-process ^2.3.0. Major aligns; please verify runtime compatibility.
-# See more keys and their definition s at https://doc.rust-lang.org/cargo/reference/manifest.html +# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html#!/bin/bash set -euo pipefail echo "Rust tauri version feature list:" rg -nP '^tauri\s*=\s*\{[^}]*features\s*=\s*\[([^\]]*)\]' frontend/src-tauri/Cargo.toml -or '$1' echo "Rust tauri-plugin-process:" rg -n 'tauri-plugin-process' frontend/src-tauri/Cargo.toml echo "JS plugin-process:" jq -r '.dependencies["@tauri-apps/plugin-process"]' frontend/package.json echo "Check devtools setting in tauri.conf.json:" rg -n '"devtools"\s*:\s*(true|false)' frontend/src-tauri/tauri.conf.json || trueAlso applies to: 8-8, 14-14, 23-23
frontend/package.json (1)
4-4: Version bump OK; verify plugin-process cross-compatMajor versions match Rust side (2.x). Please confirm the CLI and Rust/JS plugin versions are mutually compatible for your target OS matrix.
#!/bin/bash set -euo pipefail echo "CLI:" jq -r '.devDependencies["@tauri-apps/cli"]' frontend/package.json echo "JS plugin-process:" jq -r '.dependencies["@tauri-apps/plugin-process"]' frontend/package.json echo "Rust plugin-process:" rg -n 'tauri-plugin-process\s*=\s*".*"' frontend/src-tauri/Cargo.tomlIf compat is confirmed, consider using caret-less "2" on the Rust side for easier dependabot bumps to latest compatible minor.
Also applies to: 45-45
frontend/src-tauri/src/services/mod.rs (1)
966-966: Double-check tauri.conf.json mapping consistencyEnsure all resource mappings and any callers expecting “resources/server” are updated.
#!/bin/bash set -euo pipefail echo "Searching for old resource path references:" rg -n 'resources/server' || true echo "Confirm new mapping exists:" rg -n '"resources/backend"' frontend/src-tauri/tauri.conf.jsonConsider adding a parallel helper for "resources/sync-microservice" for symmetry with the new packaging.
frontend/src-tauri/capabilities/migrated.json (1)
79-79: Scope process permissions minimallyAdding "process:default" grants broad process access. Limit to only what the app needs (e.g., specific allow lists) to reduce attack surface.
#!/bin/bash set -euo pipefail echo "Ensure process plugin is actually initialized:" rg -n 'tauri_plugin_process::init' frontend/src-tauri/src/main.rs || { echo "Missing tauri_plugin_process::init() in main.rs"; exit 1; }backend/app/utils/microservice.py (2)
118-136: Optional: make dependency install idempotent/noisy-safe.
pip install -ron every start can be slow/noisy. Consider a marker file or hashingrequirements.txtto skip when unchanged.
41-44: Optional: ensure logs are visible.This module uses
logging.getLogger(__name__)but the app switched to prints elsewhere. Either configure root logging in the backend on startup or switch these key messages tofrontend/src-tauri/src/main.rs (1)
28-28: Gate debug print to dev builds.- println!("Resource path: {:?}", resource_path); + #[cfg(debug_assertions)] + println!("Resource path: {:?}", resource_path);backend/main.py (2)
69-93: Gate OpenAPI file generation to dev to avoid write failures in bundled apps.- try: + try: + if os.environ.get("GENERATE_OPENAPI", "0") != "1": + returnUsage: set
GENERATE_OPENAPI=1in dev to regenerate.
96-102: Consider restricting CORS in production.
allow_origins=["*"]is okay for local/Tauri, but consider a tighter policy (e.g., onlytauri://localhost) when shipping.frontend/src-tauri/tauri.conf.json (1)
56-58: DevTools enabled in config.Fine for development; ensure release artifacts don’t ship with DevTools enabled if that’s undesired.
frontend/src/routes/AppRoutes.tsx (1)
10-10: Swap to lazy-load ComingSoon for lighter initial bundleOptional: code-split ComingSoon since it’s used on multiple routes and not critical-path.
Apply:
-import { ComingSoon } from '@/pages/ComingSoon/ComingSoon'; +const ComingSoon = React.lazy(() => import('@/pages/ComingSoon/ComingSoon'));And wrap these routes in a Suspense boundary (e.g., around or locally).
frontend/src/components/OnboardingSteps/OnboardingStep.tsx (2)
9-9: Unify import styleUse the alias path for consistency with other imports in this file.
-import { ServerCheck } from './ServerCheck'; +import { ServerCheck } from '@/components/OnboardingSteps/ServerCheck';
41-42: Confirm step list vs. progress countSERVER_CHECK renders, but VISIBLE_STEPS excludes both SERVER_CHECK and UPDATE_STEP. If you show progress based on totalSteps, this may misreport progress when these steps run.
Consider computing totalSteps from the actual active flow or include these steps when applicable.
frontend/src/api/axiosConfig.ts (1)
13-20: Duped axios config — consider a factoryBoth clients share identical config except baseURL. Reduce duplication and centralize headers/timeouts.
-export const syncApiClient = axios.create({ - baseURL: SYNC_MICROSERVICE_URL, - timeout: 10000, // 10 seconds timeout - headers: { - 'Content-Type': 'application/json', - Accept: 'application/json', - }, -}); +const makeApiClient = (baseURL: string) => + axios.create({ + baseURL, + timeout: 10000, + headers: { 'Content-Type': 'application/json', Accept: 'application/json' }, + }); + +export const syncApiClient = makeApiClient(SYNC_MICROSERVICE_URL);Also confirm CORS/cookies needs; add withCredentials if required by the sync service.
frontend/src/api/api-functions/health.ts (1)
1-16: Add minimal error handling or document thrown errorsCalls will throw on non-2xx. If ServerCheck expects a boolean/shape, consider normalizing here; otherwise, ensure the caller has try/catch.
Example normalization:
-export const getMainBackendHealthStatus = async (): Promise<APIResponse> => { - const response = await apiClient.get<APIResponse>(healthEndpoints.healthCheck); - return response.data; -}; +export const getMainBackendHealthStatus = async (): Promise<APIResponse> => { + try { + const { data } = await apiClient.get<APIResponse>(healthEndpoints.healthCheck); + return data; + } catch (e) { + // map to your APIResponse error shape if available + throw e; + } +}frontend/src/components/Dialog/InfoDialog.tsx (1)
66-70: Prevent dismiss via ESC/click-outside when close is hiddenIf the intent is a truly non-dismissible dialog, also block onOpenChange when showCloseButton is false.
Add guards:
// around line 49-54 <Dialog open={isOpen} onOpenChange={(open) => { if (!open && showCloseButton === false) return; // ignore outside/Esc if (!open) handleClose(); }} >frontend/src/pages/ComingSoon/ComingSoon.tsx (1)
1-47: Solid placeholder; minor a11y tweakMark decorative icons as aria-hidden to reduce noise for screen readers.
- <Clock className="text-primary h-8 w-8" /> + <Clock aria-hidden="true" className="text-primary h-8 w-8" /> ... - <Sparkles className="h-5 w-5 text-yellow-500" /> + <Sparkles aria-hidden="true" className="h-5 w-5 text-yellow-500" />frontend/src/features/infoDialogSlice.ts (1)
25-30: Minor: streamline defaulting via payload destructuring.Removes repeated
action.payload.*and centralizes defaults.- state.title = action.payload.title; - state.message = action.payload.message; - state.variant = action.payload.variant || 'info'; - state.showCloseButton = action.payload.showCloseButton ?? true; + const { + title, + message, + variant = 'info', + showCloseButton = true, + } = action.payload; + state.title = title; + state.message = message; + state.variant = variant; + state.showCloseButton = showCloseButton;frontend/src/components/OnboardingSteps/ServerCheck.tsx (2)
23-27: Use unique React Query keys for health checks.
['clusters']is generic and risks cache collisions with real cluster data. Prefer specific keys.- } = usePictoQuery({ - queryKey: ['clusters'], + } = usePictoQuery({ + queryKey: ['mainBackendHealth'], queryFn: getMainBackendHealthStatus, @@ - } = usePictoQuery({ - queryKey: ['syncMicroservice'], + } = usePictoQuery({ + queryKey: ['syncHealth'], queryFn: getSyncMicroserviceHealthStatus,Also applies to: 33-37
38-56: Clear the scheduled exit timeout to avoid leaks/repeated exits.If the component unmounts or states flap, the pending timeout should be cleared.
- useEffect(() => { + useEffect(() => { + let exitTimer: number | undefined; @@ - setTimeout(() => { - exit(1); - }, 2000); + exitTimer = window.setTimeout(() => { + void exit(1); + }, 2000); } @@ - }, [ + return () => { + if (exitTimer) { + clearTimeout(exitTimer); + } + }; + }, [ mainBackendSuccess, mainBackendLoading, mainBackendError, syncMicroserviceSuccess, syncMicroserviceLoading, syncMicroserviceError, + dispatch, + stepIndex, ]);Also applies to: 61-68
frontend/src/pages/SettingsPage/Settings.tsx (3)
106-114: Disable controls while saving to prevent rapid re-submits.Tie UI interactivity to mutation pending state.
const { - mutate: updatePreferencesMutate, - isSuccess: updatePreferencesSuccess, - isError: updatePreferencesError, + mutate: updatePreferencesMutate, + isSuccess: updatePreferencesSuccess, + isError: updatePreferencesError, + isPending: updatePreferencesPending, } = usePictoMutation({ mutationFn: updateUserPreferences, });- <Button variant="outline" className="w-32 justify-between"> + <Button + variant="outline" + className="w-32 justify-between" + disabled={updatePreferencesPending} + ><Switch id="gpu-acceleration" checked={userPreferences.GPU_Acceleration} onCheckedChange={(checked) => handlePreferenceUpdate({ ...userPreferences, GPU_Acceleration: checked, }) } + disabled={updatePreferencesPending} />Also applies to: 349-353, 406-416
123-126: Make updates atomic with functional setState to avoid stale closures.Merges patches and ensures the mutation uses the latest state.
- const handlePreferenceUpdate = (updatedPreferences: UserPreferencesData) => { - setUserPreferences(updatedPreferences); - updatePreferencesMutate(updatedPreferences); - }; + const handlePreferenceUpdate = (patch: Partial<UserPreferencesData>) => { + setUserPreferences(prev => { + const next = { ...prev, ...patch }; + updatePreferencesMutate(next); + return next; + }); + };- onClick={() => - handlePreferenceUpdate({ - ...userPreferences, - YOLO_model_size: 'nano', - }) - } + onClick={() => handlePreferenceUpdate({ YOLO_model_size: 'nano' })}- onClick={() => - handlePreferenceUpdate({ - ...userPreferences, - YOLO_model_size: 'small', - }) - } + onClick={() => handlePreferenceUpdate({ YOLO_model_size: 'small' })}- onClick={() => - handlePreferenceUpdate({ - ...userPreferences, - YOLO_model_size: 'medium', - }) - } + onClick={() => handlePreferenceUpdate({ YOLO_model_size: 'medium' })}- onCheckedChange={(checked) => - handlePreferenceUpdate({ - ...userPreferences, - GPU_Acceleration: checked, - }) - } + onCheckedChange={(checked) => + handlePreferenceUpdate({ GPU_Acceleration: checked }) + }Also applies to: 357-362, 367-372, 377-382, 409-414
479-479: Simplify boolean expression.
false || xis justx.- showCloseButton={false || !isDownloading} + showCloseButton={!isDownloading}frontend/src/api/api-functions/user_preferences.ts (4)
6-22: DRY the repeated union and future‑proof sizesExtract a reusable size type/constant and use
Partial<UserPreferencesData>for the update request.-export interface UserPreferencesData { - YOLO_model_size: 'nano' | 'small' | 'medium'; - GPU_Acceleration: boolean; -} +export const YOLO_MODEL_SIZES = ['nano', 'small', 'medium'] as const; +export type YoloModelSize = typeof YOLO_MODEL_SIZES[number]; +export interface UserPreferencesData { + YOLO_model_size: YoloModelSize; + GPU_Acceleration: boolean; +} @@ -export interface UpdateUserPreferencesRequest { - YOLO_model_size?: 'nano' | 'small' | 'medium'; - GPU_Acceleration?: boolean; -} +export type UpdateUserPreferencesRequest = Partial<UserPreferencesData>;Optional: If
APIResponsesupports generics, preferAPIResponse<UserPreferencesData>over extending and addinguser_preferencesmanually.
6-9: Consider transport vs domain casingServer-style keys (
YOLO_model_size,GPU_Acceleration) are unconventional in TS UIs. Consider mapping to camelCase in the frontend domain model to isolate API wire format from UI types.
24-31: Support request cancellationExpose an optional AbortSignal to prevent orphaned in-flight calls when navigating away.
-export const getUserPreferences = - async (): Promise<GetUserPreferencesResponse> => { - const response = await apiClient.get<GetUserPreferencesResponse>( - userPreferencesEndpoints.getUserPreferences, - ); - return response.data; - }; +export const getUserPreferences = + async (options?: { signal?: AbortSignal }): Promise<GetUserPreferencesResponse> => { + const response = await apiClient.get<GetUserPreferencesResponse>( + userPreferencesEndpoints.getUserPreferences, + { signal: options?.signal }, + ); + return response.data; + };
33-41: PUT with a partial payload — confirm backend contract (else use PATCH)You’re sending a partial but using PUT (often implies full replacement). Verify backend expects PUT+partial; otherwise switch to PATCH. Added cancellation support in either case.
export const updateUserPreferences = async ( - request: UpdateUserPreferencesRequest, -): Promise<UpdateUserPreferencesResponse> => { - const response = await apiClient.put<UpdateUserPreferencesResponse>( - userPreferencesEndpoints.updateUserPreferences, - request, - ); + request: UpdateUserPreferencesRequest, + options?: { signal?: AbortSignal }, +): Promise<UpdateUserPreferencesResponse> => { + const response = await apiClient.put<UpdateUserPreferencesResponse>( + userPreferencesEndpoints.updateUserPreferences, + request, + { signal: options?.signal }, + ); return response.data; };If backend expects PATCH instead:
- const response = await apiClient.put<UpdateUserPreferencesResponse>( + const response = await apiClient.patch<UpdateUserPreferencesResponse>(Run to confirm server method/shape:
#!/bin/bash set -euo pipefail echo "Find endpoints and method for /user-preferences" rg -n -C2 -S '/user-preferences' echo "PUT/PATCH route defs" rg -n -C2 -P '@(app|router)\.(put|patch)\s*\(\s*["'\'']/user-preferences/?' echo "Confirm response keys" rg -n -C2 -S '\buser_preferences\b|\bYOLO_model_size\b|\bGPU_Acceleration\b'
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (4)
backend/dist/README.mdis excluded by!**/dist/**frontend/package-lock.jsonis excluded by!**/package-lock.jsonfrontend/src-tauri/Cargo.lockis excluded by!**/*.locksync-microservice/dist/README.mdis excluded by!**/dist/**
📒 Files selected for processing (31)
.github/workflows/build-and-release.yml(0 hunks)backend/.gitignore(1 hunks)backend/app/custom_logging.py(0 hunks)backend/app/logging_config.json(0 hunks)backend/app/utils/microservice.py(1 hunks)backend/main.py(3 hunks)docs/backend/backend_python/openapi.json(1 hunks)frontend/package.json(2 hunks)frontend/src-tauri/Cargo.toml(2 hunks)frontend/src-tauri/capabilities/migrated.json(1 hunks)frontend/src-tauri/src/main.rs(1 hunks)frontend/src-tauri/src/services/mod.rs(1 hunks)frontend/src-tauri/tauri.conf.json(2 hunks)frontend/src/App.tsx(2 hunks)frontend/src/api/api-functions/health.ts(1 hunks)frontend/src/api/api-functions/index.ts(1 hunks)frontend/src/api/api-functions/user_preferences.ts(1 hunks)frontend/src/api/apiEndpoints.ts(1 hunks)frontend/src/api/axiosConfig.ts(2 hunks)frontend/src/components/Dialog/InfoDialog.tsx(3 hunks)frontend/src/components/OnboardingSteps/OnboardingStep.tsx(2 hunks)frontend/src/components/OnboardingSteps/ServerCheck.tsx(1 hunks)frontend/src/config/Backend.ts(1 hunks)frontend/src/constants/steps.ts(1 hunks)frontend/src/features/infoDialogSlice.ts(2 hunks)frontend/src/pages/ComingSoon/ComingSoon.tsx(1 hunks)frontend/src/pages/SettingsPage/Settings.tsx(4 hunks)frontend/src/routes/AppRoutes.tsx(1 hunks)frontend/src/types/infoDialog.ts(1 hunks)sync-microservice/.gitignore(1 hunks)sync-microservice/main.py(2 hunks)
💤 Files with no reviewable changes (3)
- .github/workflows/build-and-release.yml
- backend/app/logging_config.json
- backend/app/custom_logging.py
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
- GitHub Check: Tauri Tests
- GitHub Check: Tauri Build Check (macos-latest, --target aarch64-apple-darwin)
- GitHub Check: Tauri Build Check (ubuntu-22.04)
- GitHub Check: Tauri Build Check (windows-latest)
🔇 Additional comments (29)
frontend/src-tauri/src/services/mod.rs (1)
966-966: LGTM: resource path matches new packaging layoutSwitch to resources/backend aligns with tauri.conf.json mappings.
sync-microservice/main.py (1)
27-27: ```shell
#!/bin/bash
set -eecho "Searching for Config class definition"
rg -nP 'class\s+Config' -C3 . || echo "No Config class definition found"echo "Searching for Config import statements"
rg -nP 'from\s+.*Config' -C3 . || echo "No Config imports found"echo "Checking for Dockerfile presence"
fd -t f Dockerfile || echo "No Dockerfile found"echo "Searching for port 8001 references"
rg -n "8001" -n . || echo "No references to port 8001 found"</blockquote></details> <details> <summary>backend/app/utils/microservice.py (2)</summary><blockquote> `55-62`: **Frozen path calc + new directory name look correct.** Resolving to `<resources>/sync-microservice` by using `Path(sys.executable).parent.parent / "sync-microservice"` matches the new Tauri resource mapping. --- `60-69`: **Double-check packaged executable name.** This expects `PictoPy_Sync(.exe)` inside `resources/sync-microservice`. Verify the PyInstaller output name matches to avoid “file not found” at runtime. Would you confirm the generated artifact name in the sync-microservice dist configuration? </blockquote></details> <details> <summary>frontend/src-tauri/src/main.rs (2)</summary><blockquote> `21-21`: **Process plugin inclusion looks good.** --- `27-28`: **Resource path change to `resources/backend` matches tauri.conf.json.** </blockquote></details> <details> <summary>docs/backend/backend_python/openapi.json (1)</summary><blockquote> `19-37`: **Health path and operationId updates align with backend route changes.** Move from `/` to `/health` and `root_health_get` looks consistent. </blockquote></details> <details> <summary>frontend/src/types/infoDialog.ts (1)</summary><blockquote> `8-8`: **Prop addition LGTM.** Optional with sensible default handled by the component. </blockquote></details> <details> <summary>frontend/src/api/apiEndpoints.ts (2)</summary><blockquote> `20-23`: **User preferences endpoints added correctly.** Paths match the OpenAPI trailing slash style. --- `25-27`: **Health endpoint export looks good.** </blockquote></details> <details> <summary>frontend/src/config/Backend.ts (2)</summary><blockquote> `2-2`: **Sync microservice base URL export LGTM.** Matches server default (8001) and `/api/v1` base. --- `1-3`: **Verify no stale IMAGE_ENDPOINT usages remain.** ```shell #!/bin/bash # Find any remaining references to the removed IMAGE_ENDPOINT export rg -n --hidden -S '\bIMAGE_ENDPOINT\b' -g '!**/dist/**' -g '!**/build/**'backend/main.py (2)
106-109: /health endpoint change is consistent with docs and frontend.
125-130: Uvicorn config withlog_level="info"is fine.frontend/src-tauri/tauri.conf.json (4)
25-27: Resource mappings updated correctly (backend + sync-microservice).
33-33: Version bump acknowledged.
65-65: CSP updates to allow 8000/8001 over http/ws look correct.
34-34: Update bundle identifier before release.
com.yourcompany.pictopyis a placeholder; use a stable reverse-DNS (e.g.,org.aossie.pictopy) for signing/updates.frontend/src/routes/AppRoutes.tsx (1)
18-22: Placeholder routing looks goodPointing VIDEOS, ALBUMS, and MEMORIES to ComingSoon is a safe interim. Ensure any deep links or breadcrumbs don’t assume Settings for these paths.
frontend/src/api/api-functions/index.ts (1)
5-6: Re-exports added correctlyHealth and user preferences APIs are now publicly exposed. Verify no name collisions with existing exports and that consumers update their imports from this index.
frontend/src/components/Dialog/InfoDialog.tsx (2)
21-21: Prop default LGTMshowCloseButton default keeps prior behavior while enabling non-dismissible dialogs.
55-55: Prop passthrough depends on DialogContent supportEnsure DialogContent accepts showCloseButton; otherwise this prop is ignored.
frontend/src/App.tsx (2)
18-19: InfoDialog wiring looks correctshowCloseButton is plumbed from state to InfoDialog as intended.
32-32: Prop pass-through LGTMPassing showCloseButton preserves existing behavior while enabling non-dismissible flows.
frontend/src/features/infoDialogSlice.ts (2)
9-10: LGTM: Added showCloseButton with sensible default.State shape extension is consistent and backwards-safe.
36-37: LGTM: Resetting showCloseButton on hide is correct.Prevents sticky UI state across dialogs.
frontend/src/components/OnboardingSteps/ServerCheck.tsx (1)
57-60: LGTM: Success path completes the step and hides loader.Flow is clear and side-effect boundaries are appropriate.
frontend/src/pages/SettingsPage/Settings.tsx (1)
94-105: LGTM: Local userPreferences state + initial fetch hookup.Reasonable defaults; query integration is straightforward.
frontend/src/api/api-functions/user_preferences.ts (1)
1-3: Verify alias '@' and axios client config to avoid build regressionsEnsure the
@path alias is configured in tsconfig andapiClienthas sane defaults (baseURL, timeout, withCredentials) since this module depends on both.Run:
#!/bin/bash set -euo pipefail echo "Check TS alias mapping for @/*" fd -a -HI -t f 'tsconfig*.json' rg -n -C2 '"paths"\s*:\s*{[^}]*"@/\*":' $(fd -a -HI -t f 'tsconfig*.json') echo "Locate axios client config" fd -a 'axiosConfig.ts' rg -n -C2 'create\(|baseURL|timeout|withCredentials' $(fd -a 'axiosConfig.ts')
Summary by CodeRabbit
New Features
Improvements
Chores