Notification Emails not sending via Android App #4102

Closed
opened 2026-02-05 09:43:49 +03:00 by OVERLORD · 1 comment
Owner

Originally created by @has-ctrl on GitHub (Aug 17, 2024).

The bug

When creating a new shared album with another user (who has notifications for this action turned on), email notifications do not get triggered (activity does not appear in the logs at all) when adding a user from the Android app. When using the web app however, the email is send and received as expected.

The OS that Immich Server is running on

Ubuntu 24.04 LTS

Version of Immich Server

v1.112.1

Version of Immich Mobile App

v1.112.1 build.154

Platform with the issue

  • Server
  • Web
  • Mobile

Your docker-compose.yml content

Default

Your .env content

Default

Reproduction steps

1. Open Android Immich app
2. Navigate to "Sharing" tab
3. Click "New shared album"
4. Add title and image
5. Click user to share it with
6. Verify in logs (verbose) that the album was created, but the `Microservices:NotificationRepository` does not get triggered.

Relevant log output

When creating shared album via **web app**:


immich_server            | [Nest] 17  - 08/17/2024, 4:49:12 PM   DEBUG [Api:LoggingInterceptor~fqgiyxkk] GET /api/shared-links 200 8.42ms ::ffff:xxxx
immich_server            | [Nest] 17  - 08/17/2024, 4:49:12 PM   DEBUG [Api:LoggingInterceptor~zofpi6ur] GET /api/users 200 9.78ms ::ffff:xxxx
immich_server            | [Nest] 17  - 08/17/2024, 4:49:15 PM   DEBUG [Api:LoggingInterceptor~6igdlrjd] PUT /api/albums/fc34b4b2-157d-4180-a623-83df65a209dd/users 200 54.23ms ::ffff:xxxx
immich_server            | [Nest] 17  - 08/17/2024, 4:49:15 PM VERBOSE [Api:LoggingInterceptor~6igdlrjd] {"albumUsers":[{"userId":"7a6f2164-00dc-4067-8cec-ae5d98981748","role":"editor"}]}
immich_server            | [Nest] 17  - 08/17/2024, 4:49:15 PM   DEBUG [Api:LoggingInterceptor~zq225958] GET /api/activities?albumId=fc34b4b2-157d-4180-a623-83df65a209dd&level=album&type=like&userId=fd9ab47d-b9c2-4d3f-a538-3b305b1e5e10 200 19.76ms ::ffff:xxxx
immich_server            | [Nest] 17  - 08/17/2024, 4:49:15 PM   DEBUG [Api:LoggingInterceptor~05oy1vrf] GET /api/activities/statistics?albumId=fc34b4b2-157d-4180-a623-83df65a209dd 200 7.61ms ::ffff:xxxx
immich_server            | [Nest] 7  - 08/17/2024, 4:49:15 PM   DEBUG [Microservices:NotificationRepository] Sending email to XXXX@gmail.com with subject: You have been added to a shared album - Test
immich_server            | [Nest] 7  - 08/17/2024, 4:49:17 PM     LOG [Microservices:NotificationService] Sent mail with id: <b169d73d-cdbc-00f8-f156-c313dec51b03@gmail.com> status: 250 2.0.0 OK  1723913357 a640c23a62f3a-a83838c65e7sm421652566b.20 - gsmtp

When creating shared album via Android app:

immich_server            | [Nest] 17  - 08/17/2024, 5:01:41 PM   DEBUG [Api:LoggingInterceptor~yf1jco8f] POST /api/auth/validateToken 200 0.48ms ::ffff:xxxx
immich_server            | [Nest] 17  - 08/17/2024, 5:01:48 PM   DEBUG [Api:LoggingInterceptor~yucp8d2u] POST /api/auth/validateToken 200 0.33ms ::ffff:xxxx
immich_server            | [Nest] 17  - 08/17/2024, 5:01:54 PM   DEBUG [Api:LoggingInterceptor~okx4zchr] POST /api/albums 201 39.68ms ::ffff:xxxx
immich_server            | [Nest] 17  - 08/17/2024, 5:01:54 PM VERBOSE [Api:LoggingInterceptor~okx4zchr] {"albumName":"Test Album","albumUsers":[{"role":"editor","userId":"7a6f2164-00dc-4067-8cec-ae5d98981748"}],"assetIds":[]}
immich_server            | [Nest] 17  - 08/17/2024, 5:01:54 PM   DEBUG [Api:LoggingInterceptor~s9oox1me] GET /api/users 200 3.29ms ::ffff:xxxx
immich_server            | [Nest] 17  - 08/17/2024, 5:01:54 PM   DEBUG [Api:LoggingInterceptor~lmbo7nf4] GET /api/partners?direction=shared-by 200 3.05ms ::ffff:xxxx
immich_server            | [Nest] 17  - 08/17/2024, 5:01:54 PM   DEBUG [Api:LoggingInterceptor~6z049rah] GET /api/partners?direction=shared-with 200 2.34ms ::ffff:xxxx
immich_server            | [Nest] 17  - 08/17/2024, 5:01:54 PM   DEBUG [Api:LoggingInterceptor~ek2w49ee] GET /api/albums?shared=true 200 102.42ms ::ffff:xxxx
immich_server            | [Nest] 17  - 08/17/2024, 5:01:54 PM   DEBUG [Api:LoggingInterceptor~1s65j9br] POST /api/auth/validateToken 200 0.15ms ::ffff:xxxx


### Additional information

_No response_
Originally created by @has-ctrl on GitHub (Aug 17, 2024). ### The bug When creating a new shared album with another user (who has notifications for this action turned on), email notifications do not get triggered (activity does not appear in the logs at all) when adding a user from the Android app. When using the web app however, the email is send and received as expected. ### The OS that Immich Server is running on Ubuntu 24.04 LTS ### Version of Immich Server v1.112.1 ### Version of Immich Mobile App v1.112.1 build.154 ### Platform with the issue - [ ] Server - [ ] Web - [X] Mobile ### Your docker-compose.yml content ```YAML Default ``` ### Your .env content ```Shell Default ``` ### Reproduction steps ```bash 1. Open Android Immich app 2. Navigate to "Sharing" tab 3. Click "New shared album" 4. Add title and image 5. Click user to share it with 6. Verify in logs (verbose) that the album was created, but the `Microservices:NotificationRepository` does not get triggered. ``` ### Relevant log output ```shell When creating shared album via **web app**: immich_server | [Nest] 17 - 08/17/2024, 4:49:12 PM DEBUG [Api:LoggingInterceptor~fqgiyxkk] GET /api/shared-links 200 8.42ms ::ffff:xxxx immich_server | [Nest] 17 - 08/17/2024, 4:49:12 PM DEBUG [Api:LoggingInterceptor~zofpi6ur] GET /api/users 200 9.78ms ::ffff:xxxx immich_server | [Nest] 17 - 08/17/2024, 4:49:15 PM DEBUG [Api:LoggingInterceptor~6igdlrjd] PUT /api/albums/fc34b4b2-157d-4180-a623-83df65a209dd/users 200 54.23ms ::ffff:xxxx immich_server | [Nest] 17 - 08/17/2024, 4:49:15 PM VERBOSE [Api:LoggingInterceptor~6igdlrjd] {"albumUsers":[{"userId":"7a6f2164-00dc-4067-8cec-ae5d98981748","role":"editor"}]} immich_server | [Nest] 17 - 08/17/2024, 4:49:15 PM DEBUG [Api:LoggingInterceptor~zq225958] GET /api/activities?albumId=fc34b4b2-157d-4180-a623-83df65a209dd&level=album&type=like&userId=fd9ab47d-b9c2-4d3f-a538-3b305b1e5e10 200 19.76ms ::ffff:xxxx immich_server | [Nest] 17 - 08/17/2024, 4:49:15 PM DEBUG [Api:LoggingInterceptor~05oy1vrf] GET /api/activities/statistics?albumId=fc34b4b2-157d-4180-a623-83df65a209dd 200 7.61ms ::ffff:xxxx immich_server | [Nest] 7 - 08/17/2024, 4:49:15 PM DEBUG [Microservices:NotificationRepository] Sending email to XXXX@gmail.com with subject: You have been added to a shared album - Test immich_server | [Nest] 7 - 08/17/2024, 4:49:17 PM LOG [Microservices:NotificationService] Sent mail with id: <b169d73d-cdbc-00f8-f156-c313dec51b03@gmail.com> status: 250 2.0.0 OK 1723913357 a640c23a62f3a-a83838c65e7sm421652566b.20 - gsmtp ``` When creating shared album via **Android app**: ``` immich_server | [Nest] 17 - 08/17/2024, 5:01:41 PM DEBUG [Api:LoggingInterceptor~yf1jco8f] POST /api/auth/validateToken 200 0.48ms ::ffff:xxxx immich_server | [Nest] 17 - 08/17/2024, 5:01:48 PM DEBUG [Api:LoggingInterceptor~yucp8d2u] POST /api/auth/validateToken 200 0.33ms ::ffff:xxxx immich_server | [Nest] 17 - 08/17/2024, 5:01:54 PM DEBUG [Api:LoggingInterceptor~okx4zchr] POST /api/albums 201 39.68ms ::ffff:xxxx immich_server | [Nest] 17 - 08/17/2024, 5:01:54 PM VERBOSE [Api:LoggingInterceptor~okx4zchr] {"albumName":"Test Album","albumUsers":[{"role":"editor","userId":"7a6f2164-00dc-4067-8cec-ae5d98981748"}],"assetIds":[]} immich_server | [Nest] 17 - 08/17/2024, 5:01:54 PM DEBUG [Api:LoggingInterceptor~s9oox1me] GET /api/users 200 3.29ms ::ffff:xxxx immich_server | [Nest] 17 - 08/17/2024, 5:01:54 PM DEBUG [Api:LoggingInterceptor~lmbo7nf4] GET /api/partners?direction=shared-by 200 3.05ms ::ffff:xxxx immich_server | [Nest] 17 - 08/17/2024, 5:01:54 PM DEBUG [Api:LoggingInterceptor~6z049rah] GET /api/partners?direction=shared-with 200 2.34ms ::ffff:xxxx immich_server | [Nest] 17 - 08/17/2024, 5:01:54 PM DEBUG [Api:LoggingInterceptor~ek2w49ee] GET /api/albums?shared=true 200 102.42ms ::ffff:xxxx immich_server | [Nest] 17 - 08/17/2024, 5:01:54 PM DEBUG [Api:LoggingInterceptor~1s65j9br] POST /api/auth/validateToken 200 0.15ms ::ffff:xxxx ``` ``` ### Additional information _No response_
Author
Owner

@has-ctrl commented on GitHub (Aug 19, 2024):

Whoo amazing @alextran1502, thank you!

@has-ctrl commented on GitHub (Aug 19, 2024): Whoo amazing @alextran1502, thank you!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: immich-app/immich#4102