Repository navigation
refactor: Move checkExistingAssets(), checkBulkUpdate() remove getAllAssets() - #9715
Merged
Merged
Conversation
| import { FileUploadInterceptor, Route, UploadFiles, getFiles } from 'src/middleware/file-upload.interceptor'; | ||
| import { AssetMediaService } from 'src/services/asset-media.service'; | ||
| import { FileNotEmptyValidator, UUIDParamDto } from 'src/validation'; | ||
|
|
Member
There was a problem hiding this comment.
I don't think removing this newline was intentional
danieldietzler
approved these changes
May 24, 2024
| import { AssetEntity, AssetType } from 'src/entities/asset.entity'; | ||
| import { IAlbumRepository } from 'src/interfaces/album.interface'; | ||
| import { IAssetStackRepository } from 'src/interfaces/asset-stack.interface'; | ||
| import { IAssetRepositoryV1 } from 'src/interfaces/asset-v1.interface'; |
Member
There was a problem hiding this comment.
Suggested change
| import { IAssetRepositoryV1 } from 'src/interfaces/asset-v1.interface'; |
jrasm91
approved these changes
May 25, 2024
3 tasks
Deathwalker-47
pushed a commit
to Deathwalker-47/Immich-Image-edit
that referenced
this pull request
Aug 15, 2026
None of these show up in local testing — all three only bite once the app is containerised and pointed at a real Immich. Found by checking the deploy path rather than assuming the working local build would transfer. ## 1. LoRA catalogue would load EMPTY in production lora.ts resolved master_lora_dict.json via path.join(__dirname, '../..'), which is correct from source (<repo>/backend/dist -> repo root) but resolves to '/' inside the image (/app/dist -> /). Worse, the two JSON files live at the repo root while the backend image's build context is ./backend, so they are not in the build context at all and could never have been COPYed in. Net effect: the picker renders empty, every LoRA edit silently resolves to no LoRAs, and nothing logs an error — the exact silent-degradation failure mode this project has been bitten by before. Replaced with a candidate-path resolver (env override, then the realistic Docker and local locations), mounted both files read-only in docker-compose, and added a loud startup warning naming the path it looked at, so an empty catalogue can never again be invisible. Verified against a simulated /app container layout: 81 LoRAs load, 50-entry AIR cache seeds correctly. ## 2. No volume for backend/data — every deploy wiped runtime state HANDOFF.md §8 explicitly calls for runware_lora_mapping.json to live on a persistent, volume-mounted path so container rebuilds don't force a full re-upload. That mount had never been added, so `docker compose build` also discarded settings.json along with it. Added ./backend/data:/app/data. ## 3. The gallery's timeline endpoint calls a REMOVED Immich API routes/immich.ts used GET /assets?page=&size=&order=desc — the getAllAssets endpoint removed in immich-app/immich#9715, whose documented replacement is POST /search/metadata. On current Immich this 404s. This is very likely the actual root cause of HANDOFF.md §6.5's "Failed to load photos" dead-end. That was characterised as an intermittent failure, but a removed endpoint fails 100% of the time for the "Recent Photos" view while album browsing (a different, still-valid endpoint) keeps working — which presents to a user exactly like intermittent flakiness. The retry + recoverable error state added earlier fixed how that failure *surfaced*; this fixes the cause. Switched to POST /search/metadata (the same endpoint already verified working against a real Immich in the sibling bridge project) and normalised its nested {assets:{items:[]}} response to a plain array at the backend boundary. Also taught the frontend parser that shape directly — otherwise a nested payload reaching it would be read as a non-array and render "no photos found" on a *successful* fetch. Backend and frontend both typecheck and build clean. Note that #3 remains the one thing not verifiable from here: no Immich instance is reachable from this environment, so the corrected endpoint is doc-verified and matches a known-working implementation, but has not been run against a live server.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This was split from PR #8480.
This is relocating a few controller.v1 methods into the asset-media controller:
This one is deleted, as its unused.