netease-youdao / QAnything

Question and Answer based on Anything.
https://qanything.ai
GNU Affero General Public License v3.0
11.77k stars 1.13k forks source link

[BUG] <title>develop1.5版本 milvus insert error上传文件失败 #470

Open xiaowuhhhh opened 2 months ago

xiaowuhhhh commented 2 months ago

是否已有关于该错误的issue或讨论? | Is there an existing issue / discussion for this?

该问题是否在FAQ中有解答? | Is there an existing answer for this in FAQ?

当前行为 | Current Behavior

milvus insert error 如题 微信图片_20240809154620具体保错: 2024-08-09 07:25:07,048 - [PID: 197][Sanic-Server-0-0] - [Function: process_data] - ERROR - milvus insert error: Traceback (most recent call last): File "/usr/local/lib/python3.10/site-packages/aiohttp/connector.py", line 1025, in _wrap_create_connection return await self._loop.create_connection(*args, **kwargs) File "uvloop/loop.pyx", line 2039, in create_connection File "uvloop/loop.pyx", line 2016, in uvloop.loop.Loop.create_connection ConnectionRefusedError: [Errno 111] Connection refused

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "/workspace/QAnything/qanything_kernel/dependent_server/insert_files_serve/insert_files_server.py", line 129, in process_data chunks_number, insert_time_record = await retriever.insert_documents(local_file.docs, chunk_size) File "/workspace/QAnything/qanything_kernel/utils/general_utils.py", line 146, in inner res = await func(args, kwargs) # 注意这里使用 await 来调用异步函数 File "/workspace/QAnything/qanything_kernel/core/retriever/parent_retriever.py", line 189, in insert_documents return await self.retriever.aadd_documents(embed_docs, backup_vectorstore=self.backup_vectorstore, File "/workspace/QAnything/qanything_kernel/core/retriever/parent_retriever.py", line 107, in aadd_documents res = await self.vectorstore.aadd_documents(docs, time_record=time_record) File "/usr/local/lib/python3.10/site-packages/langchain_core/vectorstores.py", line 153, in aadd_documents return await self.aadd_texts(texts, metadatas, kwargs) File "/workspace/QAnything/qanything_kernel/core/retriever/vectorstore.py", line 180, in aadd_texts embeddings = await self.embedding_func.aembed_documents(texts) File "/workspace/QAnything/qanything_kernel/utils/general_utils.py", line 146, in inner res = await func(args, *kwargs) # 注意这里使用 await 来调用异步函数 File "/workspace/QAnything/qanything_kernel/connector/embedding/embedding_for_online_client.py", line 38, in aembed_documents results = await asyncio.gather(tasks) File "/workspace/QAnything/qanything_kernel/connector/embedding/embedding_for_online_client.py", line 28, in _get_embedding_async async with session.post(self.url, json=data) as response: File "/usr/local/lib/python3.10/site-packages/aiohttp/client.py", line 1197, in aenter self._resp = await self._coro File "/usr/local/lib/python3.10/site-packages/aiohttp/client.py", line 581, in _request conn = await self._connector.connect( File "/usr/local/lib/python3.10/site-packages/aiohttp/connector.py", line 544, in connect proto = await self._create_connection(req, traces, timeout) File "/usr/local/lib/python3.10/site-packages/aiohttp/connector.py", line 944, in _createconnection , proto = await self._create_direct_connection(req, traces, timeout) File "/usr/local/lib/python3.10/site-packages/aiohttp/connector.py", line 1257, in _create_direct_connection raise last_exc File "/usr/local/lib/python3.10/site-packages/aiohttp/connector.py", line 1226, in _create_direct_connection transp, proto = await self._wrap_create_connection( File "/usr/local/lib/python3.10/site-packages/aiohttp/connector.py", line 1033, in _wrap_create_connection raise client_error(req.connection_key, exc) from exc aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host localhost:9001 ssl:default [Connection refused]

期望行为 | Expected Behavior

No response

运行环境 | Environment

- OS:Ubuntu 22.04/vmware
- NVIDIA Driver:无
- CUDA:无
- docker:与教程一致
- docker-compose:与教程一致
- NVIDIA GPU:未使用gpu
- NVIDIA GPU Memory:未使用gpu

QAnything日志 | QAnything logs

No response

复现方法 | Steps To Reproduce

No response

备注 | Anything else?

No response

xiaowuhhhh commented 2 months ago

dd

xiayi0409 commented 1 month ago

您好 请问解决了吗