[GH-ISSUE #16852] issue: "index.ts:363 Uncaught (in promise) ReferenceError: $i18n is not defined" #33602

Closed
opened 2026-04-25 07:30:25 -05:00 by GiteaMirror · 1 comment
Owner

Originally created by @masx200 on GitHub (Aug 23, 2025).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/16852

Check Existing Issues

  • I have searched the existing issues and discussions.
  • I am using the latest version of Open WebUI.

Installation Method

Docker

Open WebUI Version

v0.6.25

Ollama Version (if applicable)

No response

Operating System

windows 11

Browser (if applicable)

chrome 139

Confirmation

  • I have read and followed all instructions in README.md.
  • I am using the latest version of both Open WebUI and Ollama.
  • I have included the browser console logs.
  • I have included the Docker container logs.
  • I have provided every relevant configuration, setting, and environment variable used in my setup.
  • I have clearly listed every relevant configuration, custom setting, environment variable, and command-line option that influences my setup (such as Docker Compose overrides, .env values, browser settings, authentication configurations, etc).
  • I have documented step-by-step reproduction instructions that are precise, sequential, and leave nothing to interpretation. My steps:
  • Start with the initial platform/version/OS and dependencies used,
  • Specify exact install/launch/configure commands,
  • List URLs visited, user input (incl. example values/emails/passwords if needed),
  • Describe all options and toggles enabled or changed,
  • Include any files or environmental changes,
  • Identify the expected and actual result at each stage,
  • Ensure any reasonably skilled user can follow and hit the same issue.

Expected Behavior

Load the dialog page correctly.

Actual Behavior

index.ts:327 TypeError: Failed to fetch
    at window.fetch (fetcher.js:76:10)
    at fs (index.ts:307:20)
    at index.ts:356:25
    at Array.map (<anonymous>)
    at Ss (index.ts:355:6)
    at 2.B9WpmhRh.js:sourcemap:113:15052
(匿名) @ index.ts:327
Promise.catch
fs @ index.ts:326
(匿名) @ index.ts:356
Ss @ index.ts:355
(匿名) @ 2.B9WpmhRh.js:sourcemap:113
index.ts:363 Uncaught (in promise) ReferenceError: $i18n is not defined
    at index.ts:363:8
    at async index.ts:356:19
    at async Promise.all (/index 0)
    at async Ss (index.ts:352:3)
    at async 2.B9WpmhRh.js:sourcemap:113:15046

Steps to Reproduce

管理工具服务器

http://100.73.82.85:29999/tavily-search
API 密钥
••••••••••••••••••••••••••••••••••••••••••••••••••


http://100.73.82.85:29999/baidu-map-mcp-server
API 密钥
••••••••••••••••••••••••••••••••••••••••••••••••••


http://100.73.82.85:29999/firecrawl-mcp-server
API 密钥
•••••••••••••••••••••••••••••••••••••••••••••••••••


http://100.73.82.85:29999/context7
API 密钥
••••••••••••••••••••••••••••••••••••••••••••••••••


连接到您自有的 OpenAPI 兼容外部工具服务器
提供商必须正确配置 CORS 以允许来自 Open WebUI 的请求
[进一步了解 OpenAPI 工具服务器](https://github.com/open-webui/openapi-servers)

after I created a tool for admin users in open-webui, if the URL of this tool is not accessible to the current network, it causes the page to not load!

Logs & Screenshots

index.ts:327 TypeError: Failed to fetch
    at window.fetch (fetcher.js:76:10)
    at fs (index.ts:307:20)
    at index.ts:356:25
    at Array.map (<anonymous>)
    at Ss (index.ts:355:6)
    at 2.B9WpmhRh.js:sourcemap:113:15052
(匿名) @ index.ts:327
Promise.catch
fs @ index.ts:326
(匿名) @ index.ts:356
Ss @ index.ts:355
(匿名) @ 2.B9WpmhRh.js:sourcemap:113
index.ts:363 Uncaught (in promise) ReferenceError: $i18n is not defined
    at index.ts:363:8
    at async index.ts:356:19
    at async Promise.all (/index 0)
    at async Ss (index.ts:352:3)
    at async 2.B9WpmhRh.js:sourcemap:113:15046

Additional Information


export const getToolServersData = async (i18n, servers: object[]) => {
	return (
		await Promise.all(
			servers
				.filter((server) => server?.config?.enable)
				.map(async (server) => {
					const data = await getToolServerData(
						(server?.auth_type ?? 'bearer') === 'bearer' ? server?.key : localStorage.token,
						(server?.path ?? '').includes('://')
							? server?.path
							: `${server?.url}${(server?.path ?? '').startsWith('/') ? '' : '/'}${server?.path}`
					).catch((err) => {
						toast.error(
							$i18n.t(`Failed to connect to {{URL}} OpenAPI tool server`, {
								URL: (server?.path ?? '').includes('://')
									? server?.path
									: `${server?.url}${(server?.path ?? '').startsWith('/') ? '' : '/'}${server?.path}`
							})
						);
						return null;
					});

					if (data) {
						const { openapi, info, specs } = data;
						return {
							url: server?.url,
							openapi: openapi,
							info: info,
							specs: specs
						};
					}
				})
		)
	).filter((server) => server);
};
Originally created by @masx200 on GitHub (Aug 23, 2025). Original GitHub issue: https://github.com/open-webui/open-webui/issues/16852 ### Check Existing Issues - [x] I have searched the existing issues and discussions. - [x] I am using the latest version of Open WebUI. ### Installation Method Docker ### Open WebUI Version v0.6.25 ### Ollama Version (if applicable) _No response_ ### Operating System windows 11 ### Browser (if applicable) chrome 139 ### Confirmation - [x] I have read and followed all instructions in `README.md`. - [x] I am using the latest version of **both** Open WebUI and Ollama. - [x] I have included the browser console logs. - [x] I have included the Docker container logs. - [x] I have **provided every relevant configuration, setting, and environment variable used in my setup.** - [x] I have clearly **listed every relevant configuration, custom setting, environment variable, and command-line option that influences my setup** (such as Docker Compose overrides, .env values, browser settings, authentication configurations, etc). - [x] I have documented **step-by-step reproduction instructions that are precise, sequential, and leave nothing to interpretation**. My steps: - Start with the initial platform/version/OS and dependencies used, - Specify exact install/launch/configure commands, - List URLs visited, user input (incl. example values/emails/passwords if needed), - Describe all options and toggles enabled or changed, - Include any files or environmental changes, - Identify the expected and actual result at each stage, - Ensure any reasonably skilled user can follow and hit the same issue. ### Expected Behavior Load the dialog page correctly. ### Actual Behavior ``` index.ts:327 TypeError: Failed to fetch at window.fetch (fetcher.js:76:10) at fs (index.ts:307:20) at index.ts:356:25 at Array.map (<anonymous>) at Ss (index.ts:355:6) at 2.B9WpmhRh.js:sourcemap:113:15052 (匿名) @ index.ts:327 Promise.catch fs @ index.ts:326 (匿名) @ index.ts:356 Ss @ index.ts:355 (匿名) @ 2.B9WpmhRh.js:sourcemap:113 index.ts:363 Uncaught (in promise) ReferenceError: $i18n is not defined at index.ts:363:8 at async index.ts:356:19 at async Promise.all (/index 0) at async Ss (index.ts:352:3) at async 2.B9WpmhRh.js:sourcemap:113:15046 ``` ### Steps to Reproduce ``` 管理工具服务器 http://100.73.82.85:29999/tavily-search API 密钥 •••••••••••••••••••••••••••••••••••••••••••••••••• http://100.73.82.85:29999/baidu-map-mcp-server API 密钥 •••••••••••••••••••••••••••••••••••••••••••••••••• http://100.73.82.85:29999/firecrawl-mcp-server API 密钥 ••••••••••••••••••••••••••••••••••••••••••••••••••• http://100.73.82.85:29999/context7 API 密钥 •••••••••••••••••••••••••••••••••••••••••••••••••• 连接到您自有的 OpenAPI 兼容外部工具服务器 提供商必须正确配置 CORS 以允许来自 Open WebUI 的请求 [进一步了解 OpenAPI 工具服务器](https://github.com/open-webui/openapi-servers) ``` after I created a tool for admin users in open-webui, if the URL of this tool is not accessible to the current network, it causes the page to not load! ### Logs & Screenshots ``` index.ts:327 TypeError: Failed to fetch at window.fetch (fetcher.js:76:10) at fs (index.ts:307:20) at index.ts:356:25 at Array.map (<anonymous>) at Ss (index.ts:355:6) at 2.B9WpmhRh.js:sourcemap:113:15052 (匿名) @ index.ts:327 Promise.catch fs @ index.ts:326 (匿名) @ index.ts:356 Ss @ index.ts:355 (匿名) @ 2.B9WpmhRh.js:sourcemap:113 index.ts:363 Uncaught (in promise) ReferenceError: $i18n is not defined at index.ts:363:8 at async index.ts:356:19 at async Promise.all (/index 0) at async Ss (index.ts:352:3) at async 2.B9WpmhRh.js:sourcemap:113:15046 ``` ### Additional Information ```ts export const getToolServersData = async (i18n, servers: object[]) => { return ( await Promise.all( servers .filter((server) => server?.config?.enable) .map(async (server) => { const data = await getToolServerData( (server?.auth_type ?? 'bearer') === 'bearer' ? server?.key : localStorage.token, (server?.path ?? '').includes('://') ? server?.path : `${server?.url}${(server?.path ?? '').startsWith('/') ? '' : '/'}${server?.path}` ).catch((err) => { toast.error( $i18n.t(`Failed to connect to {{URL}} OpenAPI tool server`, { URL: (server?.path ?? '').includes('://') ? server?.path : `${server?.url}${(server?.path ?? '').startsWith('/') ? '' : '/'}${server?.path}` }) ); return null; }); if (data) { const { openapi, info, specs } = data; return { url: server?.url, openapi: openapi, info: info, specs: specs }; } }) ) ).filter((server) => server); }; ```
GiteaMirror added the bug label 2026-04-25 07:30:25 -05:00
Author
Owner

@tjbck commented on GitHub (Aug 26, 2025):

Addressed with f4047eea7797fa1bf0a541bf2f2e02331537dbf9!

<!-- gh-comment-id:3223320800 --> @tjbck commented on GitHub (Aug 26, 2025): Addressed with f4047eea7797fa1bf0a541bf2f2e02331537dbf9!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#33602