Conversation
- pnpm-workspace.yaml: add audit overrides for transitive CVEs (nanoid, undici, js-yaml, postcss, brace-expansion, esbuild, dompurify) - Restore package.json/pnpm-lock.yaml from master to resolve stash pop conflicts
- Login: isLoading state, disabled button, AUTHENTICATING text, error-pulse animation, spacing/divider fixes - Dwellers: HappinessDashboard loading prop + skeleton, tighter spacing, 480px single-column grid - Map: marker hover glow, top-right zoom controls, responsive legend, empty-state Recruit CTA - Backend: add is_unlocked bool to DwellerLocationBase + Alembic migration with index Verification: lint/typecheck/tests pass, alembic head 0ca13298230f, DB column/index confirmed
- Add is_unlocked to DwellerRef and WastelandLocationWithDwellers schemas - Add unlock_places_for_dweller CRUD and count_user_messages_to_dweller helper - Trigger unlock after 3+ user messages in chat_service (process_text_message + stream_response) - Propagate is_unlocked through map_service with optional unlocked_only filter - Add unlocked_only query param to map endpoint - Add tests for unlock behavior, CRUD, and map service filtering Verification: 1496 passed, 2 skipped (32.92s)
- Add is_unlocked to map models (generated types now include it) - MapMarker: locked state (lock-question icon, dashed outline, 50% opacity, Unknown Location label) - MarkerDetailModal: locked placeholder with hint to chat with dweller - WorldMap: pass is_unlocked to markers - Map store: unlockedPlacesCount getter + refreshMap action - Chat integration: trigger map refresh after send, watch unlock count, toast on new locations - Add/update unit tests for MapMarker, MarkerDetailModal, DwellerChat Verification: lint/typecheck/tests pass (1121 passed, 1 skipped)
- Remove unsupported --skip-types-generate flag from webServer command - Update interaction.spec.ts side-panel nav items to match current UI (remove 'Happiness', add 'Map') Verification: 163 Playwright e2e tests pass
for more information, see https://pre-commit.ci
|
Warning Review limit reached
Next review available in: 22 minutes You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (10)
📝 WalkthroughWalkthroughThe change adds persisted dweller-location unlock state. Chat activity unlocks linked locations after three user messages. Backend map responses, frontend map rendering, chat refresh behavior, loading states, responsive layouts, and frontend tooling are updated. ChangesLocation unlocking
Frontend UI and tooling updates
Estimated code review effort: 4 (Complex) | ~60 minutes Possibly related PRs
Sequence Diagram(s)sequenceDiagram
participant Dweller
participant ChatService
participant CRUDChatMessage
participant CRUDWastelandLocation
participant MapService
Dweller->>ChatService: Send messages
ChatService->>CRUDChatMessage: Count user messages
CRUDChatMessage-->>ChatService: Return count
ChatService->>CRUDWastelandLocation: Unlock linked locations at count three
ChatService-->>Dweller: Return chat response
Dweller->>MapService: Refresh vault map
MapService-->>Dweller: Return updated unlock states
sequenceDiagram
participant DwellerChat
participant useChatActions
participant useMapStore
participant MapView
DwellerChat->>useChatActions: Send text message
useChatActions-->>DwellerChat: Complete chat action
DwellerChat->>useChatActions: Call refreshAfterChat
useChatActions->>useMapStore: Refresh map for vault
useMapStore-->>MapView: Update locations and unlockedPlacesCount
MapView-->>DwellerChat: Show newly uncovered location toast
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (3 passed)
✨ Finishing Touches 💡 2📝 Generate docstrings 💡
🛠️ Fix failing CI checks 💡
🧪 Generate unit tests (beta)
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 |
There was a problem hiding this comment.
Actionable comments posted: 10
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
frontend/src/modules/map/components/MarkerDetailModal.vue (1)
69-90: 🎯 Functional Correctness | 🟠 Major | ⚡ Quick winKeep the modal locked state consistent with map markers.
isLockedtreatshome_vaultas locked whenis_unlockedis false. This hides Home Vault details, althoughMapMarkerexplicitly keeps home-vault markers unlocked and the map service retains them without DwellerLocation references. The modal title also still usesplaceName, so it exposes a locked location name above the placeholder.Exclude
home_vaultfromisLocked. Bind the modal title toUnknown Locationwhen a non-home location is locked.Proposed fix
-const isLocked = computed(() => props.location !== null && !props.location.is_unlocked) +const isLocked = computed( + () => + props.location !== null && + props.location.type !== 'home_vault' && + !props.location.is_unlocked +) +const modalTitle = computed(() => (isLocked.value ? 'Unknown Location' : placeName.value))- <UModal v-model="isOpen" :title="placeName" size="lg"> + <UModal v-model="isOpen" :title="modalTitle" size="lg">🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@frontend/src/modules/map/components/MarkerDetailModal.vue` around lines 69 - 90, Update the isLocked computed value to exclude locations whose type is home_vault, matching MapMarker behavior. Change the UModal title binding to display “Unknown Location” for locked non-home locations while preserving placeName for unlocked and home-vault locations.
🧹 Nitpick comments (1)
frontend/playwright.config.ts (1)
19-19: 🩺 Stability & Availability | 🔵 TrivialVerify backend startup before running E2E tests.
pnpm run devrunstypes:generatefirst. That script fetcheshttp://localhost:8000/api/v1/openapi.json. This Playwright configuration starts only the frontend server on port5173. If CI does not start the backend separately, Playwright fails before any test runs. Confirm the backend startup and health-check order. (raw.githubusercontent.com)🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@frontend/playwright.config.ts` at line 19, Update the Playwright webServer configuration around the dev command to ensure the backend is started and healthy before running the frontend’s types:generate step. Preserve the existing frontend startup on port 5173, and configure the startup/health-check order so the OpenAPI endpoint on localhost:8000 is available before E2E tests begin.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@backend/app/crud/wasteland_location.py`:
- Around line 205-210: Update unlock_places_for_dweller so its DwellerLocation
update filters for the given dweller_id and is_unlocked == false before setting
is_unlocked to true, preserving the returned rowcount and commit behavior.
In `@backend/app/services/chat_service.py`:
- Around line 486-495: Update _maybe_unlock_places to catch unexpected errors
from counting or unlocking places, roll back the database session when needed,
and log the failure with logger.exception(...). Keep this helper best-effort by
preventing the exception from propagating so non-streaming responses succeed and
streaming flows can emit done.
- Line 486: Update the new _maybe_unlock_places method signature to
type-annotate dweller with the concrete type returned by get_full_info, or
change the parameter to dweller_id: UUID4 and adjust the implementation
accordingly; keep the existing behavior unchanged.
In `@frontend/pnpm-workspace.yaml`:
- Around line 33-36: Update the minimumReleaseAgeExclude entries for dompurify
and js-yaml to exact audited package versions rather than bare package names,
and align the pnpm override targets with those exact versions. Preserve the
existing esbuild configuration and ensure future releases remain subject to the
seven-day delay.
In `@frontend/src/modules/chat/components/DwellerChat.vue`:
- Line 107: In the location-uncovered notification flow, split the overlong
toast.success expression by extracting the count difference and plural suffix
into local variables before constructing the message. Keep the existing
singular/plural behavior and notification text unchanged.
- Around line 103-110: Initialize a map-count baseline before chat messages are
loaded, and update the watcher around mapStore.unlockedPlacesCount so the first
response from an empty store is treated as initialization rather than a new
unlock. Suppress the toast for that initial map response, while preserving
notifications for subsequent count increases.
- Around line 112-115: Update the voice-message flow to call refreshAfterChat
after sendAudioMessage completes successfully, matching handleSendMessage’s
behavior. Locate the sendAudioMessage handler and preserve existing error
handling while ensuring successful voice messages refresh the map immediately.
In `@frontend/src/modules/dwellers/views/DwellersView.vue`:
- Around line 338-343: Update the DwellersView dashboard branch to remain in its
loading state until currentVault, dwellerStore.allDwellers, and
incidentStore.activeIncidents have finished loading. Track or reuse the relevant
fetch-state signals from the mounted data-loading flow, use them in the
v-if/loading behavior, and replace the hard-coded HappinessDashboard
:loading="false" value with the combined readiness state.
In `@frontend/src/modules/map/stores/map.ts`:
- Around line 97-99: Update the catch block in the map refresh flow to capture
the caught error and, when gen matches _pollGeneration, call handleStoreError
with post-chat refresh context and assign the resulting error to error; preserve
the stale-generation early return so outdated requests remain ignored.
In `@frontend/tests/unit/components/chat/DwellerChat.test.ts`:
- Around line 119-126: Wrap mock values referenced by vi.mock factories in
vi.hoisted, including mockToastSuccess, mockFetchRooms, the exploration mocks,
and mockRefreshMap. Update the affected vi.mock factories to use the hoisted
values while preserving their existing behavior and interfaces.
---
Outside diff comments:
In `@frontend/src/modules/map/components/MarkerDetailModal.vue`:
- Around line 69-90: Update the isLocked computed value to exclude locations
whose type is home_vault, matching MapMarker behavior. Change the UModal title
binding to display “Unknown Location” for locked non-home locations while
preserving placeName for unlocked and home-vault locations.
---
Nitpick comments:
In `@frontend/playwright.config.ts`:
- Line 19: Update the Playwright webServer configuration around the dev command
to ensure the backend is started and healthy before running the frontend’s
types:generate step. Preserve the existing frontend startup on port 5173, and
configure the startup/health-check order so the OpenAPI endpoint on
localhost:8000 is available before E2E tests begin.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro Plus
Run ID: 796022e9-71c2-41d5-b438-354089edb683
⛔ Files ignored due to path filters (2)
frontend/pnpm-lock.yamlis excluded by!**/pnpm-lock.yamlfrontend/src/core/types/api.generated.tsis excluded by!**/*.generated.*
📒 Files selected for processing (29)
backend/app/alembic/versions/2026_08_10_0001-0ca13298230f_add_dweller_location_is_unlocked.pybackend/app/api/v1/endpoints/map.pybackend/app/crud/chat_message.pybackend/app/crud/wasteland_location.pybackend/app/models/wasteland_location.pybackend/app/schemas/wasteland_location.pybackend/app/services/chat_service.pybackend/app/services/map_service.pybackend/app/tests/test_crud/test_wasteland_location.pybackend/app/tests/test_services/test_chat_service.pybackend/app/tests/test_services/test_map_service.pyfrontend/playwright.config.tsfrontend/pnpm-workspace.yamlfrontend/src/modules/auth/components/LoginFormTerminal.vuefrontend/src/modules/chat/components/DwellerChat.vuefrontend/src/modules/chat/components/DwellerChatPage.vuefrontend/src/modules/chat/composables/useChatActions.tsfrontend/src/modules/dwellers/views/DwellersView.vuefrontend/src/modules/map/components/MapLegend.vuefrontend/src/modules/map/components/MapMarker.vuefrontend/src/modules/map/components/MarkerDetailModal.vuefrontend/src/modules/map/components/WorldMap.vuefrontend/src/modules/map/stores/map.tsfrontend/src/modules/map/views/MapView.vuefrontend/src/modules/vault/components/HappinessDashboard.vuefrontend/tests/e2e/interaction.spec.tsfrontend/tests/unit/components/chat/DwellerChat.test.tsfrontend/tests/unit/components/map/MapMarker.test.tsfrontend/tests/unit/components/map/MarkerDetailModal.test.ts
Summary by CodeRabbit