Cesc
254081462c
fix(memory): apply Docker localhost rewrite in embedding provider constructor
...
Model listing and chat provider construction rewrite localhost to
host.docker.internal via config.DockerLocalhost() when running inside
Docker, but all three memory.NewOpenAIEmbeddingProvider call sites
(verify-embedding handler, runtime memory embedding) passed the raw
api_base through. In Docker the container resolved localhost to itself,
so Ollama Verify Embedding and runtime embedding failed with connection
refused while the model dropdown loaded fine.
Centralize the rewrite inside the constructor so no call site can miss
it, add a SetInDockerForTest hook for environment-independent regression
tests, and pin Docker detection off in httptest-based suites.
Fixes #1519
2026-08-21 10:57:36 +07:00
..
2026-06-11 13:49:58 +01:00
2026-07-31 18:30:28 +07:00
2026-03-06 18:51:11 +07:00
2026-04-09 21:15:19 +07:00
2026-05-18 20:33:40 +07:00
2026-04-09 21:15:19 +07:00
2026-05-22 20:53:01 +07:00
2026-05-24 11:27:02 +07:00
2026-05-24 11:27:02 +07:00
2026-04-09 21:15:19 +07:00
2026-04-09 21:15:19 +07:00
2026-03-10 00:09:15 +07:00
2026-06-25 10:23:55 +07:00
2026-07-31 18:30:28 +07:00
2026-08-21 10:57:36 +07:00
2026-07-30 14:17:40 +07:00
2026-04-09 21:15:19 +07:00
2026-07-10 22:25:45 +07:00
2026-06-21 14:00:36 +07:00
2026-07-10 01:24:39 +07:00
2026-07-09 04:24:19 +07:00
2026-04-09 23:15:08 +07:00
2026-08-07 14:35:59 +07:00
2026-07-30 14:17:40 +07:00
2026-05-28 18:30:34 +07:00
2026-07-07 09:53:02 +07:00
2026-05-28 18:30:34 +07:00
2026-05-28 18:30:34 +07:00
2026-06-12 15:17:57 +07:00
2026-07-07 01:21:12 +07:00
2026-03-31 23:14:39 +07:00
2026-07-30 14:17:40 +07:00
2026-07-10 22:25:45 +07:00
2026-07-10 22:25:45 +07:00
2026-07-30 14:17:40 +07:00
2026-07-30 14:17:40 +07:00
2026-04-18 14:53:42 +07:00
2026-04-14 18:28:31 +07:00
2026-07-07 09:53:02 +07:00
2026-07-07 10:52:17 +07:00
2026-07-10 22:25:45 +07:00
2026-07-10 22:25:45 +07:00
2026-07-30 14:17:40 +07:00
2026-07-30 14:17:40 +07:00
2026-07-08 20:53:19 +07:00
2026-04-15 20:40:25 +07:00
2026-04-20 08:49:38 +07:00
2026-04-12 19:03:47 +07:00
2026-04-10 20:52:28 +07:00
2026-03-27 09:28:42 +07:00
2026-05-18 21:43:03 +07:00
2026-07-10 22:25:45 +07:00
2026-05-24 11:13:03 +07:00
2026-06-12 09:48:01 +07:00
2026-06-12 15:01:38 +07:00
2026-06-12 14:42:48 +07:00
2026-07-10 22:25:45 +07:00
2026-07-15 09:56:43 +07:00
2026-05-31 13:08:24 +07:00
2026-05-31 13:08:24 +07:00
2026-07-31 21:30:01 +07:00
2026-07-30 14:17:40 +07:00
2026-07-15 09:56:43 +07:00
2026-02-22 14:58:07 +07:00
2026-02-22 14:58:07 +07:00
2026-05-11 15:41:27 +07:00
2026-07-20 02:38:15 +08:00
2026-07-20 02:38:15 +08:00
2026-03-19 13:35:57 +07:00
2026-03-19 13:35:57 +07:00
2026-04-15 11:24:57 +07:00
2026-08-02 12:30:08 +07:00
2026-03-19 13:35:57 +07:00
2026-03-27 09:28:42 +07:00
2026-03-27 09:28:42 +07:00
2026-03-27 09:28:42 +07:00
2026-07-31 18:30:28 +07:00
2026-07-30 14:17:40 +07:00
2026-07-30 14:17:40 +07:00
2026-07-30 14:17:40 +07:00
2026-07-30 14:17:40 +07:00
2026-05-24 15:57:21 +07:00
2026-07-09 04:54:15 +07:00
2026-07-07 01:21:12 +07:00
2026-07-07 01:21:12 +07:00
2026-06-24 15:26:26 +07:00
2026-07-31 19:34:40 +07:00
2026-02-22 14:58:07 +07:00
2026-04-04 06:58:15 +07:00
2026-08-03 22:50:12 +07:00
2026-07-31 19:34:40 +07:00
2026-07-05 12:26:42 +07:00
2026-07-05 12:26:42 +07:00
2026-03-11 07:27:38 +07:00
2026-07-03 20:23:47 +07:00
2026-04-09 21:15:19 +07:00
2026-06-12 09:48:01 +07:00
2026-03-07 00:46:29 +07:00
2026-07-20 02:38:15 +08:00
2026-04-09 21:15:19 +07:00
2026-06-12 09:48:01 +07:00
2026-03-06 18:51:11 +07:00
2026-06-12 10:40:59 +07:00
2026-06-12 10:40:59 +07:00
2026-04-09 21:15:19 +07:00
2026-04-09 21:15:19 +07:00
2026-07-20 02:38:15 +08:00
2026-06-12 14:57:09 +07:00
2026-06-12 14:50:33 +07:00
2026-06-12 10:38:53 +07:00
2026-06-12 10:38:53 +07:00
2026-06-12 10:38:53 +07:00
2026-04-16 15:49:50 +07:00
2026-04-09 21:15:19 +07:00
2026-04-16 15:49:50 +07:00
2026-04-16 15:49:50 +07:00
2026-06-12 09:48:01 +07:00
2026-06-12 09:48:01 +07:00
2026-06-12 09:48:01 +07:00
2026-06-12 09:48:01 +07:00
2026-06-12 09:48:01 +07:00
2026-06-12 09:48:01 +07:00
2026-04-09 21:15:19 +07:00
2026-04-09 21:15:19 +07:00
2026-04-09 21:15:19 +07:00
2026-04-09 21:15:19 +07:00
2026-04-09 21:15:19 +07:00
2026-04-09 21:15:19 +07:00
2026-03-07 20:51:39 +07:00
2026-04-13 10:59:27 +07:00
2026-04-13 10:59:27 +07:00