Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG]: For the case of error reporting when uploading files | 对于上传时文件时出现报错的情况 #33

Closed
codeacme17 opened this issue Sep 4, 2023 · 24 comments
Assignees
Labels
bug Something isn't working

Comments

@codeacme17
Copy link
Owner

codeacme17 commented Sep 4, 2023

Description of the bug

Appear in:#31

265305903-3a9012a2-9cdf-4d6e-b60e-f9abef7323f3

I currently think it is due to limits caused by users using unpaid Openai accounts, of course, it may also be caused by other problems. This week I will focus on solving this bug


我目前认为是由于用户使用未付费的 Openai 账号使得出现了限制, 当然也有可能是由于其他的问题导致的。这本周我会专注于解决这个 Bug

@codeacme17
Copy link
Owner Author

My current idea is that for unpaid users, the concurrency will be limited to 1, and there won't be any restrictions on retry attempts.


我目前的想法是,如果是未付费用户,则将并发量控制为1,不进行 retry 次数的限制。

@jwz520
Copy link

jwz520 commented Sep 6, 2023

@codeacme17 ,又出现新的问题了,传不上去
image

@codeacme17
Copy link
Owner Author

@jwz520 可以看看您的 个人配置页面的内容么,这个报错是因为 api_base 出现的

@jwz520
Copy link

jwz520 commented Sep 6, 2023

只填了一个api key
image

@codeacme17
Copy link
Owner Author

codeacme17 commented Sep 6, 2023

只填了一个api key

ok, 那您是否更新了代码,确保删除了之前的容器,并且重新启动了。 可以看这里的更新步骤 https://github.com/codeacme17/examor#%EF%B8%8F-update-the-project

@jwz520
Copy link

jwz520 commented Sep 6, 2023

copy下来代码,只执行了 docker-compose up -d --build 命令

@jwz520
Copy link

jwz520 commented Sep 6, 2023

@codeacme17 ,需要把 images 也删除更新吗?

@codeacme17
Copy link
Owner Author

@codeacme17 ,需要把 images 也删除更新吗?

没事,不需要,给我一些时间修复这个问题

@jwz520
Copy link

jwz520 commented Sep 6, 2023

更新了,但还是不行,这是个什么问题呀

@codeacme17
Copy link
Owner Author

现在在容器里环境变量有些问题,所以拿不到url地址

@codeacme17
Copy link
Owner Author

@jwz520 我更新了代码,请进行尝试

@jwz520
Copy link

jwz520 commented Sep 6, 2023

@codeacme17 ,又成这样了,一直在上传中😅
image

@codeacme17
Copy link
Owner Author

codeacme17 commented Sep 6, 2023

很奇怪,我使用你的文件上传没有遇到这个问题。你试着用 docker-compose up --build 这个命令去启动,然后看看控制台中是否有 server 的报错,如果有请发送给我 @jwz520。或者你将 container 和 image 都删除,然后在 compose 一下,关注一下控制台信息,不要隐藏控制台的 log

@jwz520
Copy link

jwz520 commented Sep 6, 2023

这是docker-compose up --build 之后的,我看着好像没有报错吧!也不行,我再试试将container 和 image删除
$ docker-compose up --build
2023/09/06 17:44:55 http2: server: error reading preface from client //./pipe/docker_engine: file has already been closed
#0 building with "default" instance using docker driver

#1 [database internal] load .dockerignore
#1 transferring context: 2B done
#1 DONE 0.0s

#2 [database internal] load build definition from Dockerfile
#2 transferring dockerfile: 158B done
#2 DONE 0.0s

#3 [database internal] load metadata for docker.io/library/mysql:8.0
#3 DONE 2.5s

#4 [database 1/2] FROM docker.io/library/mysql:8.0@sha256:f0e71f077bb27fe17b1b9551f75d1b35ad4dfe3a33c82412acf19684790f3a30
#4 DONE 0.0s

#5 [database internal] load build context
#5 transferring context: 34B done
#5 DONE 0.0s

#6 [database 2/2] COPY ./database.sql /docker-entrypoint-initdb.d/
#6 CACHED

#7 [database] exporting to image
#7 exporting layers done
#7 writing image sha256:1f8b30ff5813c6977bfd9f2ed715c39502401b7b7b9286b219055ab5224bfd55 done
#7 naming to docker.io/library/examor-main-database done
#7 DONE 0.0s

#8 [server internal] load build definition from Dockerfile
#8 transferring dockerfile: 355B done
#8 DONE 0.0s

#9 [server internal] load .dockerignore
#9 transferring context: 64B done
#9 DONE 0.0s

#10 [server internal] load metadata for docker.io/library/python:3.11.3
#10 DONE 3.3s

#11 [server 1/8] FROM docker.io/library/python:3.11.3@sha256:3a619e3c96fd4c5fc5e1998fd4dcb1f1403eb90c4c6409c70d7e80b9468df7df
#11 DONE 0.0s

#12 [server internal] load build context
#12 transferring context: 1.53kB done
#12 DONE 0.0s

#13 [server 7/8] COPY . .
#13 CACHED

#14 [server 2/8] WORKDIR /app
#14 CACHED

#15 [server 5/8] COPY wait-for-it.sh .
#15 CACHED

#16 [server 4/8] RUN pip install -r requirements.txt
#16 CACHED

#17 [server 3/8] COPY requirements.txt .
#17 CACHED

#18 [server 6/8] RUN ls -a
#18 CACHED

#19 [server 8/8] RUN chmod +x wait-for-it.sh
#19 CACHED

#20 [server] exporting to image
#20 exporting layers done
#20 writing image sha256:1e4c7762d075849b21ba8e0c77e3b0da16eb7a506eebe409a36c4e7b0ac229dc done
#20 naming to docker.io/library/examor-main-server done
#20 DONE 0.0s

#21 [app internal] load build definition from Dockerfile
#21 transferring dockerfile: 231B done
#21 DONE 0.0s

#22 [app internal] load .dockerignore
#22 transferring context: 57B done
#22 DONE 0.0s

#23 [app internal] load metadata for docker.io/library/node:18-alpine
#23 DONE 1.7s

#24 [app 1/5] FROM docker.io/library/node:18-alpine@sha256:3482a20c97e401b56ac50ba8920cc7b5b2022bfc6aa7d4e4c231755770cf892f
#24 DONE 0.0s

#25 [app internal] load build context
#25 transferring context: 4.75kB 0.0s done
#25 DONE 0.0s

#26 [app 4/5] RUN npm install -g pnpm && pnpm install && rm -rf /node_modules/.vite
#26 CACHED

#27 [app 2/5] WORKDIR /app
#27 CACHED

#28 [app 3/5] COPY package.json pnpm-lock.yaml ./
#28 CACHED

#29 [app 5/5] COPY . .
#29 CACHED

#30 [app] exporting to image
#30 exporting layers done
#30 writing image sha256:71d52703b546a5599ff759fb663d41acd0aae903ea14b7565812674113501a47 done
#30 naming to docker.io/library/examor-main-app done
#30 DONE 0.0s
Container examor-main-database-1 Created
Container examor-main-server-1 Created
Container examor-main-app-1 Created
Attaching to examor-main-app-1, examor-main-database-1, examor-main-server-1
examor-main-database-1 | 2023-09-06 09:45:03+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.34-1.el8 started.
examor-main-database-1 | 2023-09-06 09:45:03+00:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
examor-main-database-1 | 2023-09-06 09:45:03+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.34-1.el8 started.
examor-main-database-1 | '/var/lib/mysql/mysql.sock' -> '/var/run/mysqld/mysqld.sock'
examor-main-server-1 | wait-for-it.sh: waiting 15 seconds for database:3306
examor-main-database-1 | 2023-09-06T09:45:04.061310Z 0 [Warning] [MY-011068] [Server] The syntax '--skip-host-cache' is deprecated and will be removed in a future release. Please use SET GLOBAL host_cache_size=0 instead.
examor-main-database-1 | 2023-09-06T09:45:04.062299Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.34) starting as process 1
examor-main-database-1 | 2023-09-06T09:45:04.067272Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
examor-main-database-1 | 2023-09-06T09:45:04.158278Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
examor-main-database-1 | 2023-09-06T09:45:04.339652Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
examor-main-database-1 | 2023-09-06T09:45:04.339729Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
examor-main-database-1 | 2023-09-06T09:45:04.342654Z 0 [Warning] [MY-011810] [Server] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory.
examor-main-database-1 | 2023-09-06T09:45:04.360550Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Bind-address: '::' port: 33060, socket: /var/run/mysqld/mysqlx.sock
examor-main-database-1 | 2023-09-06T09:45:04.360771Z 0 [System] [MY-010931] [Server] /usr/sbin/mysqld: ready for connections. Version: '8.0.34' socket: '/var/run/mysqld/mysqld.sock' port: 3306 MySQL Community Server - GPL.
examor-main-server-1 | wait-for-it.sh: database:3306 is available after 1 seconds
examor-main-server-1 | INFO: Started server process [1]
examor-main-server-1 | INFO: Waiting for application startup.
examor-main-server-1 | INFO: Application startup complete.
examor-main-server-1 | INFO: Uvicorn running on http://0.0.0.0:51717 (Press CTRL+C to quit)
examor-main-app-1 |
examor-main-app-1 | > app@0.2.2 dev:docker /app
examor-main-app-1 | > vite --host --force
examor-main-app-1 |
examor-main-app-1 |
examor-main-app-1 | Forced re-optimization of dependencies
examor-main-app-1 |
examor-main-app-1 | VITE v4.4.9 ready in 697 ms
examor-main-app-1 |
examor-main-app-1 |
examor-main-app-1 | ➜ Local: http://localhost:51818/
examor-main-app-1 | ➜ Network: http://172.18.0.4:51818/
examor-main-server-1 | INFO: ('172.18.0.1', 51214) - "WebSocket /ws/file/uploading" [accepted]
examor-main-server-1 | INFO: connection open
examor-main-server-1 | INFO: 172.18.0.4:46520 - "GET /note/notes HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:46526 - "GET /profile HTTP/1.1" 200 OK
examor-main-app-1 | 9:47:31 AM [vite] ✨ new dependencies optimized: vuetify/lib/components/VGrid/index.mjs, vuetify/lib/components/VTabs/index.mjs, vuetify/lib/components/VApp/index.mjs, vuetify/lib/components/VLayout/index.mjs, vuetify/lib/components/VImg/index.mjs, vuetify/lib/components/VMenu/index.mjs, vuetify/lib/components/VTextField/index.mjs, vuetify/lib/components/VDialog/index.mjs, vuetify/lib/components/VTable/index.mjs, vuetify/lib/components/VNavigationDrawer/index.mjs, vuetify/lib/components/VMain/index.mjs, tdesign-vue-next/es/locale/en_US, tdesign-vue-next/es/locale/zh_CN, vuetify/lib/components/VSystemBar/index.mjs
examor-main-app-1 | 9:47:31 AM [vite] ✨ optimized dependencies changed. reloading
examor-main-server-1 | INFO: connection closed
examor-main-server-1 | INFO: ('172.18.0.1', 50176) - "WebSocket /ws/file/uploading" [accepted]
examor-main-server-1 | INFO: connection open
examor-main-server-1 | INFO: 172.18.0.4:33710 - "GET /note/notes HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:33720 - "GET /profile HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:33732 - "GET /note/1/files HTTP/1.1" 200 OK
examor-main-server-1 | Data deleted successfully.
examor-main-server-1 | INFO: 172.18.0.4:34570 - "DELETE /note/1 HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:34582 - "GET /note/notes HTTP/1.1" 200 OK
examor-main-app-1 | 9:47:49 AM [vite] ✨ new dependencies optimized: vuetify/lib/components/VSlider/index.mjs, vuetify/lib/components/VAlert/index.mjs, vuetify/lib/components/VFileInput/index.mjs, vuetify/lib/components/VCheckbox/index.mjs, vuetify/lib/components/VForm/index.mjs
examor-main-app-1 | 9:47:49 AM [vite] ✨ optimized dependencies changed. reloading
examor-main-server-1 | INFO: connection closed
examor-main-server-1 | INFO: ('172.18.0.1', 48320) - "WebSocket /ws/file/uploading" [accepted]
examor-main-server-1 | INFO: connection open
examor-main-server-1 | INFO: 172.18.0.4:44482 - "GET /note/notes HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:44484 - "GET /profile HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:52598 - "GET /profile HTTP/1.1" 200 OK
examor-main-server-1 | <Response [200]>
examor-main-server-1 | INFO: 172.18.0.4:43080 - "GET /profile/auth/llm HTTP/1.1" 200 OK
examor-main-server-1 | New data inserted successfully.
examor-main-server-1 | New data inserted successfully.
examor-main-server-1 | INFO: 172.18.0.4:58038 - "POST /note HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:58044 - "GET /note/notes HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:56974 - "GET /note/2/files HTTP/1.1" 200 OK
examor-main-app-1 exited with code 0
examor-main-app-1 exited with code 0
examor-main-server-1 | INFO: Shutting down
examor-main-server-1 | INFO: connection closed
examor-main-server-1 | INFO: Waiting for application shutdown.
examor-main-server-1 | INFO: Application shutdown complete.
examor-main-server-1 | INFO: Finished server process [1]
examor-main-server-1 exited with code 0
examor-main-server-1 exited with code 0
examor-main-database-1 | 2023-09-06T09:52:42.052258Z 0 [System] [MY-013172] [Server] Received SHUTDOWN from user . Shutting down mysqld (Version: 8.0.34).
examor-main-database-1 | 2023-09-06T09:52:42.764665Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.34) MySQL Community Server - GPL.

@jwz520
Copy link

jwz520 commented Sep 6, 2023

@codeacme17 ,这是删除后运行的,还是不行
$ docker-compose up
#0 building with "default" instance using docker driver

#1 [database internal] load .dockerignore
#1 transferring context: 2B done
#1 DONE 0.0s

#2 [database internal] load build definition from Dockerfile
#2 transferring dockerfile: 158B done
#2 DONE 0.0s

#3 [database internal] load metadata for docker.io/library/mysql:8.0
#3 DONE 2.2s

#4 [database 1/2] FROM docker.io/library/mysql:8.0@sha256:f0e71f077bb27fe17b1b9551f75d1b35ad4dfe3a33c82412acf19684790f3a30
#4 DONE 0.0s

#5 [database internal] load build context
#5 transferring context: 34B done
#5 DONE 0.0s

#6 [database 2/2] COPY ./database.sql /docker-entrypoint-initdb.d/
#6 CACHED

#7 [database] exporting to image
#7 exporting layers done
#7 writing image sha256:1f8b30ff5813c6977bfd9f2ed715c39502401b7b7b9286b219055ab5224bfd55 done
#7 naming to docker.io/library/examor-main-database done
#7 DONE 0.0s

#8 [server internal] load .dockerignore
#8 transferring context: 64B done
#8 DONE 0.0s

#9 [server internal] load build definition from Dockerfile
#9 transferring dockerfile: 355B done
#9 DONE 0.0s

#10 [server internal] load metadata for docker.io/library/python:3.11.3
#10 DONE 3.4s

#11 [server 1/8] FROM docker.io/library/python:3.11.3@sha256:3a619e3c96fd4c5fc5e1998fd4dcb1f1403eb90c4c6409c70d7e80b9468df7df
#11 DONE 0.0s

#12 [server internal] load build context
#12 transferring context: 1.53kB done
#12 DONE 0.0s

#13 [server 7/8] COPY . .
#13 CACHED

#14 [server 2/8] WORKDIR /app
#14 CACHED

#15 [server 4/8] RUN pip install -r requirements.txt
#15 CACHED

#16 [server 6/8] RUN ls -a
#16 CACHED

#17 [server 5/8] COPY wait-for-it.sh .
#17 CACHED

#18 [server 3/8] COPY requirements.txt .
#18 CACHED

#19 [server 8/8] RUN chmod +x wait-for-it.sh
#19 CACHED

#20 [server] exporting to image
#20 exporting layers done
#20 writing image sha256:1e4c7762d075849b21ba8e0c77e3b0da16eb7a506eebe409a36c4e7b0ac229dc done
#20 naming to docker.io/library/examor-main-server done
#20 DONE 0.0s

#21 [app internal] load .dockerignore
#21 transferring context: 57B done
#21 DONE 0.0s

#22 [app internal] load build definition from Dockerfile
#22 transferring dockerfile: 231B done
#22 DONE 0.0s

#23 [app internal] load metadata for docker.io/library/node:18-alpine
#23 DONE 1.5s

#24 [app 1/5] FROM docker.io/library/node:18-alpine@sha256:3482a20c97e401b56ac50ba8920cc7b5b2022bfc6aa7d4e4c231755770cf892f
#24 DONE 0.0s

#25 [app internal] load build context
#25 transferring context: 4.75kB 0.0s done
#25 DONE 0.0s

#26 [app 4/5] RUN npm install -g pnpm && pnpm install && rm -rf /node_modules/.vite
#26 CACHED

#27 [app 2/5] WORKDIR /app
#27 CACHED

#28 [app 3/5] COPY package.json pnpm-lock.yaml ./
#28 CACHED

#29 [app 5/5] COPY . .
#29 CACHED

#30 [app] exporting to image
#30 exporting layers done
#30 writing image sha256:71d52703b546a5599ff759fb663d41acd0aae903ea14b7565812674113501a47 done
#30 naming to docker.io/library/examor-main-app done
#30 DONE 0.0s
Network examor-main_default Creating
Network examor-main_default Created
Container examor-main-database-1 Creating
Container examor-main-database-1 Created
Container examor-main-server-1 Creating
Container examor-main-server-1 Created
Container examor-main-app-1 Creating
Container examor-main-app-1 Created
Attaching to examor-main-app-1, examor-main-database-1, examor-main-server-1
examor-main-database-1 | 2023-09-06 10:04:32+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.34-1.el8 started.
examor-main-database-1 | 2023-09-06 10:04:32+00:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
examor-main-database-1 | 2023-09-06 10:04:32+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 8.0.34-1.el8 started.
examor-main-server-1 | wait-for-it.sh: waiting 15 seconds for database:3306
examor-main-database-1 | 2023-09-06 10:04:32+00:00 [Note] [Entrypoint]: Initializing database files
examor-main-database-1 | 2023-09-06T10:04:32.828752Z 0 [Warning] [MY-011068] [Server] The syntax '--skip-host-cache' is deprecated and will be removed in a future release. Please use SET GLOBAL host_cache_size=0 instead.
examor-main-database-1 | 2023-09-06T10:04:32.829298Z 0 [System] [MY-013169] [Server] /usr/sbin/mysqld (mysqld 8.0.34) initializing of server in progress as process 81
examor-main-database-1 | 2023-09-06T10:04:32.840191Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
examor-main-database-1 | 2023-09-06T10:04:33.155647Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
examor-main-database-1 | 2023-09-06T10:04:34.247714Z 6 [Warning] [MY-010453] [Server] root@localhost is created with an empty password ! Please consider switching off the --initialize-insecure option.
examor-main-database-1 | 2023-09-06 10:04:36+00:00 [Note] [Entrypoint]: Database files initialized
examor-main-database-1 | 2023-09-06 10:04:36+00:00 [Note] [Entrypoint]: Starting temporary server
examor-main-database-1 | 2023-09-06T10:04:36.647393Z 0 [Warning] [MY-011068] [Server] The syntax '--skip-host-cache' is deprecated and will be removed in a future release. Please use SET GLOBAL host_cache_size=0 instead.
examor-main-database-1 | 2023-09-06T10:04:36.648387Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.34) starting as process 125
examor-main-database-1 | 2023-09-06T10:04:36.659967Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
examor-main-database-1 | 2023-09-06T10:04:36.754039Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
examor-main-database-1 | 2023-09-06T10:04:36.973308Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
examor-main-database-1 | 2023-09-06T10:04:36.973388Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
examor-main-database-1 | 2023-09-06T10:04:36.975717Z 0 [Warning] [MY-011810] [Server] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory.
examor-main-database-1 | 2023-09-06T10:04:36.989611Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Socket: /var/run/mysqld/mysqlx.sock
examor-main-database-1 | 2023-09-06T10:04:36.989838Z 0 [System] [MY-010931] [Server] /usr/sbin/mysqld: ready for connections. Version: '8.0.34' socket: '/var/run/mysqld/mysqld.sock' port: 0 MySQL Community Server - GPL.
examor-main-database-1 | 2023-09-06 10:04:36+00:00 [Note] [Entrypoint]: Temporary server started.
examor-main-database-1 | '/var/lib/mysql/mysql.sock' -> '/var/run/mysqld/mysqld.sock'
examor-main-database-1 | Warning: Unable to load '/usr/share/zoneinfo/iso3166.tab' as time zone. Skipping it.
examor-main-database-1 | Warning: Unable to load '/usr/share/zoneinfo/leap-seconds.list' as time zone. Skipping it.
examor-main-database-1 | Warning: Unable to load '/usr/share/zoneinfo/leapseconds' as time zone. Skipping it.
examor-main-database-1 | Warning: Unable to load '/usr/share/zoneinfo/tzdata.zi' as time zone. Skipping it.
examor-main-database-1 | Warning: Unable to load '/usr/share/zoneinfo/zone.tab' as time zone. Skipping it.
examor-main-database-1 | Warning: Unable to load '/usr/share/zoneinfo/zone1970.tab' as time zone. Skipping it.
examor-main-database-1 | 2023-09-06 10:04:38+00:00 [Note] [Entrypoint]: Creating database db
examor-main-database-1 |
examor-main-database-1 |
examor-main-database-1 | 2023-09-06 10:04:38+00:00 [Note] [Entrypoint]: /usr/local/bin/docker-entrypoint.sh: running /docker-entrypoint-initdb.d/database.sql
examor-main-database-1 |
examor-main-database-1 |
examor-main-database-1 |
examor-main-database-1 | 2023-09-06 10:04:38+00:00 [Note] [Entrypoint]: Stopping temporary server
examor-main-database-1 | 2023-09-06T10:04:38.871455Z 12 [System] [MY-013172] [Server] Received SHUTDOWN from user root. Shutting down mysqld (Version: 8.0.34).
examor-main-database-1 | 2023-09-06T10:04:40.626043Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.34) MySQL Community Server - GPL.
examor-main-database-1 | 2023-09-06 10:04:40+00:00 [Note] [Entrypoint]: Temporary server stopped
examor-main-database-1 |
examor-main-database-1 |
examor-main-database-1 | 2023-09-06 10:04:40+00:00 [Note] [Entrypoint]: MySQL init process done. Ready for start up.
examor-main-database-1 |
examor-main-database-1 |
examor-main-database-1 | 2023-09-06T10:04:41.069673Z 0 [Warning] [MY-011068] [Server] The syntax '--skip-host-cache' is deprecated and will be removed in a future release. Please use SET GLOBAL host_cache_size=0 instead.
examor-main-database-1 | 2023-09-06T10:04:41.070574Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.34) starting as process 1
examor-main-database-1 | 2023-09-06T10:04:41.075648Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
examor-main-database-1 | 2023-09-06T10:04:41.162699Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
examor-main-database-1 | 2023-09-06T10:04:41.353513Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
examor-main-database-1 | 2023-09-06T10:04:41.353558Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
examor-main-database-1 | 2023-09-06T10:04:41.355780Z 0 [Warning] [MY-011810] [Server] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory.
examor-main-database-1 | 2023-09-06T10:04:41.369151Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Bind-address: '::' port: 33060, socket: /var/run/mysqld/mysqlx.sock
examor-main-database-1 | 2023-09-06T10:04:41.369224Z 0 [System] [MY-010931] [Server] /usr/sbin/mysqld: ready for connections. Version: '8.0.34' socket: '/var/run/mysqld/mysqld.sock' port: 3306 MySQL Community Server - GPL.
examor-main-server-1 | wait-for-it.sh: database:3306 is available after 9 seconds
examor-main-server-1 | INFO: Started server process [1]
examor-main-server-1 | INFO: Waiting for application startup.
examor-main-server-1 | INFO: Application startup complete.
examor-main-server-1 | INFO: Uvicorn running on http://0.0.0.0:51717 (Press CTRL+C to quit)
examor-main-app-1 |
examor-main-app-1 | > app@0.2.2 dev:docker /app
examor-main-app-1 | > vite --host --force
examor-main-app-1 |
examor-main-app-1 |
examor-main-app-1 | Forced re-optimization of dependencies
examor-main-app-1 |
examor-main-app-1 | VITE v4.4.9 ready in 910 ms
examor-main-app-1 |
examor-main-app-1 | ➜ Local: http://localhost:51818/
examor-main-app-1 |
examor-main-app-1 | ➜ Network: http://172.18.0.4:51818/
examor-main-server-1 | INFO: ('172.18.0.1', 58144) - "WebSocket /ws/file/uploading" [accepted]
examor-main-server-1 | INFO: connection open
examor-main-server-1 | New data inserted successfully.
examor-main-server-1 | INFO: 172.18.0.4:42432 - "GET /note/notes HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:42446 - "GET /profile HTTP/1.1" 200 OK
examor-main-app-1 | 10:06:24 AM [vite] ✨ new dependencies optimized: vuetify/lib/components/VGrid/index.mjs, vuetify/lib/components/VTabs/index.mjs, vuetify/lib/components/VApp/index.mjs, vuetify/lib/components/VLayout/index.mjs, vuetify/lib/components/VImg/index.mjs, vuetify/lib/components/VNavigationDrawer/index.mjs, vuetify/lib/components/VDialog/index.mjs, vuetify/lib/components/VTable/index.mjs, vuetify/lib/components/VMain/index.mjs, vuetify/lib/components/VMenu/index.mjs, vuetify/lib/components/VTextField/index.mjs, tdesign-vue-next/es/locale/en_US, tdesign-vue-next/es/locale/zh_CN, vuetify/lib/components/VSystemBar/index.mjs
examor-main-app-1 | 10:06:24 AM [vite] ✨ optimized dependencies changed. reloading
examor-main-server-1 | INFO: connection closed
examor-main-server-1 | INFO: ('172.18.0.1', 58150) - "WebSocket /ws/file/uploading" [accepted]
examor-main-server-1 | INFO: connection open
examor-main-server-1 | INFO: 172.18.0.4:42458 - "GET /note/notes HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:42470 - "GET /profile HTTP/1.1" 200 OK
examor-main-app-1 | 10:06:48 AM [vite] ✨ new dependencies optimized: vuetify/lib/components/VSlider/index.mjs, vuetify/lib/components/VAlert/index.mjs, vuetify/lib/components/VCheckbox/index.mjs, vuetify/lib/components/VForm/index.mjs, vuetify/lib/components/VFileInput/index.mjs
examor-main-app-1 | 10:06:48 AM [vite] ✨ optimized dependencies changed. reloading
examor-main-server-1 | INFO: connection closed
examor-main-server-1 | INFO: ('172.18.0.1', 34488) - "WebSocket /ws/file/uploading" [accepted]
examor-main-server-1 | INFO: connection open
examor-main-server-1 | INFO: 172.18.0.4:34150 - "GET /note/notes HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:34164 - "GET /profile HTTP/1.1" 200 OK
examor-main-server-1 | Data updated successfully.
examor-main-server-1 | INFO: 172.18.0.4:54312 - "PUT /profile HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:42716 - "GET /profile HTTP/1.1" 200 OK
examor-main-server-1 | <Response [200]>
examor-main-server-1 | INFO: 172.18.0.4:55784 - "GET /profile/auth/llm HTTP/1.1" 200 OK
examor-main-server-1 | New data inserted successfully.
examor-main-server-1 | New data inserted successfully.
examor-main-server-1 | INFO: 172.18.0.4:42990 - "POST /note HTTP/1.1" 200 OK
examor-main-server-1 | INFO: 172.18.0.4:42998 - "GET /note/notes HTTP/1.1" 200 OK
image
这块有几条警告

@codeacme17
Copy link
Owner Author

好的,我这几天去搞一个 免费账号来测试一下这个问题到底是为什么会发生,感谢你的协助,请等待我最新的消息

@codeacme17
Copy link
Owner Author

@jwz520 我刚刚更新了修复,请在尝试一下~

@jwz520
Copy link

jwz520 commented Sep 8, 2023

@codeacme17 ,又有了新bug,server启动不了
L Community Server - GPL.
examor-main-server-1 | wait-for-it.sh: database:3306 is available after 1 seconds
examor-main-server-1 | Traceback (most recent call last):
examor-main-server-1 | File "/usr/local/bin/uvicorn", line 8, in
examor-main-server-1 | sys.exit(main())
examor-main-server-1 | ^^^^^^
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/click/core.py", line 1157, in call
examor-main-server-1 | return self.main(*args, **kwargs)
examor-main-server-1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/click/core.py", line 1078, in main
examor-main-server-1 | rv = self.invoke(ctx)
examor-main-server-1 | ^^^^^^^^^^^^^^^^
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/click/core.py", line 1434, in invoke
examor-main-server-1 | return ctx.invoke(self.callback, **ctx.params)
examor-main-server-1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/click/core.py", line 783, in invoke
examor-main-server-1 | return __callback(*args, **kwargs)
examor-main-server-1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/uvicorn/main.py", line 416, in main
examor-main-server-1 | run(
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/uvicorn/main.py", line 587, in run
examor-main-server-1 | server.run()
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/uvicorn/server.py", line 61, in run
examor-main-server-1 | return asyncio.run(self.serve(sockets=sockets))
examor-main-server-1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
examor-main-server-1 | File "/usr/local/lib/python3.11/asyncio/runners.py", line 190, in run
examor-main-server-1 | return runner.run(main)
examor-main-server-1 | ^^^^^^^^^^^^^^^^
examor-main-server-1 | File "/usr/local/lib/python3.11/asyncio/runners.py", line 118, in run
examor-main-server-1 | return self._loop.run_until_complete(task)
examor-main-server-1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
examor-main-server-1 | File "/usr/local/lib/python3.11/asyncio/base_events.py", line 653, in run_until_complete
examor-main-server-1 | return future.result()
examor-main-server-1 | ^^^^^^^^^^^^^^^
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/uvicorn/server.py", line 68, in serve
examor-main-server-1 | config.load()
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/uvicorn/config.py", line 467, in load
examor-main-server-1 | self.loaded_app = import_from_string(self.app)
examor-main-server-1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/uvicorn/importer.py", line 24, in import_from_string
examor-main-server-1 | raise exc from None
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/uvicorn/importer.py", line 21, in import_from_string
examor-main-server-1 | module = importlib.import_module(module_str)
examor-main-server-1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
examor-main-server-1 | File "/usr/local/lib/python3.11/importlib/init.py", line 126, in import_module
examor-main-server-1 | return _bootstrap._gcd_import(name[level:], package, level)
examor-main-server-1 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
examor-main-server-1 | File "", line 1206, in _gcd_import
examor-main-server-1 | File "", line 1178, in _find_and_load
examor-main-server-1 | File "", line 1149, in _find_and_load_unlocked
examor-main-server-1 | File "", line 690, in _load_unlocked
examor-main-server-1 | File "", line 940, in exec_module
examor-main-server-1 | File "", line 241, in _call_with_frames_removed
examor-main-server-1 | File "/app/main.py", line 4, in
examor-main-server-1 | import apis as apis
examor-main-server-1 | File "/app/apis/init.py", line 1, in
examor-main-server-1 | from . import note
examor-main-server-1 | File "/app/apis/note.py", line 2, in
examor-main-server-1 | import db_services as dbs
examor-main-server-1 | File "/app/db_services/init.py", line 5, in
examor-main-server-1 | from . import profile
examor-main-server-1 | File "/app/db_services/profile.py", line 5, in
examor-main-server-1 | from utils import types
examor-main-server-1 | File "/app/utils/init.py", line 1, in
examor-main-server-1 | from .file_handler import upload_file
examor-main-server-1 | File "/app/utils/file_handler.py", line 6, in
examor-main-server-1 | from loaders import split_doc
examor-main-server-1 | File "/app/loaders/init.py", line 3, in
examor-main-server-1 | from .markdown import MarkdownLoader
examor-main-server-1 | File "/app/loaders/markdown.py", line 3, in
examor-main-server-1 | from .share import len_token, MAX_TOKEN, is_the_token_exceeded, is_there_no_enough_content, is_odd_backtick_paired
examor-main-server-1 | File "/app/loaders/share.py", line 1, in
examor-main-server-1 | import tiktoken
examor-main-server-1 | ModuleNotFoundError: No module named 'tiktoken'
examor-main-server-1 exited with code 0

@jwz520
Copy link

jwz520 commented Sep 8, 2023

OK

@codeacme17
Copy link
Owner Author

@jwz520 ,抱歉这个报错是由于 tiktoken 这个模块没有下载,我误以为 langchain 会依赖这个模块,所以没有将他写入到 requirement 文件中,我已经更新了代码~

@jwz520
Copy link

jwz520 commented Sep 9, 2023

@codeacme17 ,还是有问题,server启动不了
examor-main-server-1 | wait-for-it.sh: database:3306 is available after 1 seconds
examor-main-server-1 | INFO: Started server process [1]
examor-main-server-1 | INFO: Waiting for application startup.
examor-main-server-1 | ERROR: Traceback (most recent call last):
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/routing.py", line 677, in lifespan
examor-main-server-1 | async with self.lifespan_context(app) as maybe_state:
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/routing.py", line 566, in aenter
examor-main-server-1 | await self._router.startup()
examor-main-server-1 | File "/usr/local/lib/python3.11/site-packages/starlette/routing.py", line 656, in startup
examor-main-server-1 | handler()
examor-main-server-1 | File "/app/main.py", line 15, in startup
examor-main-server-1 | dbs.profile.set_profile_to_env()
examor-main-server-1 | File "/app/db_services/profile.py", line 65, in set_profile_to_env
examor-main-server-1 | os.environ['OPENAI_MODEL'] = data['openaiModel'] or "gpt-3.5-turbo"
examor-main-server-1 | ~~~~^^^^^^^^^^^^^^^
examor-main-server-1 | KeyError: 'openaiModel'
examor-main-server-1 |
examor-main-server-1 | ERROR: Application startup failed. Exiting.
examor-main-server-1 |
examor-main-server-1 exited with code 0

@codeacme17
Copy link
Owner Author

请尝试将之前的 container 删除在 compose 一下,这个问题应该是数据库的内容没有更新
@jwz520

@jwz520
Copy link

jwz520 commented Sep 9, 2023

这回可以上传了😄

@codeacme17
Copy link
Owner Author

这回可以上传了😄

谢天谢地,我重写了上传的逻辑,如果你的账号是未付费版上传时间会比较长,这是因为为了避免 openai 的 rate limits。我将会关闭这个 issue,十分感谢你这段时间的协助!我会将你的名字放在项目的 README 简介中,如果遇到其他问题,很欢迎再次创建 issue 与我沟通~

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants