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

2.8.5运行错误 #848

Closed
echs-top opened this issue Apr 29, 2024 · 2 comments
Closed

2.8.5运行错误 #848

echs-top opened this issue Apr 29, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@echs-top
Copy link

简述:在将2.8.3的artalk替换为2.8.5版本后重新运行报错

恢复2.8.3运行正常

artalk.log日志文件如下:

{"level":"INFO","ts":"2024-04-30T03:16:54.514+0800","caller":"[dao/migrate.go:57]","msg":"[DB Migrator] Generating Root IDs..."}
{"level":"ERROR","ts":"2024-04-30T03:16:54.522+0800","caller":"[dao/base.go:27]","msg":"[DB]","error":"Error 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'UPDATE comments SET root_id = (\n\t\tSELECT root_id\n\t\tFROM CommentHierarchy\n\t\tWH...' at line 12","elapsed":0.000336569,"rows":-1,"sql":"WITH RECURSIVE CommentHierarchy AS (\n\t\tSELECT id, id AS root_id, rid\n\t\tFROM comments\n\t\tWHERE rid = 0\n\n\t\tUNION ALL\n\n\t\tSELECT c.id, ch.root_id, c.rid\n\t\tFROM comments c\n\t\tINNER JOIN CommentHierarchy ch ON c.rid = ch.id\n\t)\n\tUPDATE comments SET root_id = (\n\t\tSELECT root_id\n\t\tFROM CommentHierarchy\n\t\tWHERE comments.id = CommentHierarchy.id\n\t);\n\t"}
{"level":"FATAL","ts":"2024-04-30T03:16:54.528+0800","caller":"[dao/migrate.go:81]","msg":"[DB Migrator] Failed to generate root IDs, please feedback this issue to the Artalk team."}
{"level":"INFO","ts":"2024-04-30T03:16:55.565+0800","caller":"[dao/migrate.go:57]","msg":"[DB Migrator] Generating Root IDs..."}
{"level":"ERROR","ts":"2024-04-30T03:16:55.573+0800","caller":"[dao/base.go:27]","msg":"[DB]","error":"Error 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'UPDATE comments SET root_id = (\n\t\tSELECT root_id\n\t\tFROM CommentHierarchy\n\t\tWH...' at line 12","elapsed":0.000317245,"rows":-1,"sql":"WITH RECURSIVE CommentHierarchy AS (\n\t\tSELECT id, id AS root_id, rid\n\t\tFROM comments\n\t\tWHERE rid = 0\n\n\t\tUNION ALL\n\n\t\tSELECT c.id, ch.root_id, c.rid\n\t\tFROM comments c\n\t\tINNER JOIN CommentHierarchy ch ON c.rid = ch.id\n\t)\n\tUPDATE comments SET root_id = (\n\t\tSELECT root_id\n\t\tFROM CommentHierarchy\n\t\tWHERE comments.id = CommentHierarchy.id\n\t);\n\t"}
{"level":"FATAL","ts":"2024-04-30T03:16:55.579+0800","caller":"[dao/migrate.go:81]","msg":"[DB Migrator] Failed to generate root IDs, please feedback this issue to the Artalk team."}
{"level":"INFO","ts":"2024-04-30T03:16:58.204+0800","caller":"[dao/migrate.go:57]","msg":"[DB Migrator] Generating Root IDs..."}
{"level":"ERROR","ts":"2024-04-30T03:16:58.211+0800","caller":"[dao/base.go:27]","msg":"[DB]","error":"Error 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'UPDATE comments SET root_id = (\n\t\tSELECT root_id\n\t\tFROM CommentHierarchy\n\t\tWH...' at line 12","elapsed":0.00032878,"rows":-1,"sql":"WITH RECURSIVE CommentHierarchy AS (\n\t\tSELECT id, id AS root_id, rid\n\t\tFROM comments\n\t\tWHERE rid = 0\n\n\t\tUNION ALL\n\n\t\tSELECT c.id, ch.root_id, c.rid\n\t\tFROM comments c\n\t\tINNER JOIN CommentHierarchy ch ON c.rid = ch.id\n\t)\n\tUPDATE comments SET root_id = (\n\t\tSELECT root_id\n\t\tFROM CommentHierarchy\n\t\tWHERE comments.id = CommentHierarchy.id\n\t);\n\t"}
{"level":"FATAL","ts":"2024-04-30T03:16:58.217+0800","caller":"[dao/migrate.go:81]","msg":"[DB Migrator] Failed to generate root IDs, please feedback this issue to the Artalk team."}
{"level":"INFO","ts":"2024-04-30T03:17:01.612+0800","caller":"[dao/migrate.go:57]","msg":"[DB Migrator] Generating Root IDs..."}
{"level":"ERROR","ts":"2024-04-30T03:17:01.619+0800","caller":"[dao/base.go:27]","msg":"[DB]","error":"Error 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'UPDATE comments SET root_id = (\n\t\tSELECT root_id\n\t\tFROM CommentHierarchy\n\t\tWH...' at line 12","elapsed":0.000342219,"rows":-1,"sql":"WITH RECURSIVE CommentHierarchy AS (\n\t\tSELECT id, id AS root_id, rid\n\t\tFROM comments\n\t\tWHERE rid = 0\n\n\t\tUNION ALL\n\n\t\tSELECT c.id, ch.root_id, c.rid\n\t\tFROM comments c\n\t\tINNER JOIN CommentHierarchy ch ON c.rid = ch.id\n\t)\n\tUPDATE comments SET root_id = (\n\t\tSELECT root_id\n\t\tFROM CommentHierarchy\n\t\tWHERE comments.id = CommentHierarchy.id\n\t);\n\t"}
{"level":"FATAL","ts":"2024-04-30T03:17:01.625+0800","caller":"[dao/migrate.go:81]","msg":"[DB Migrator] Failed to generate root IDs, please feedback this issue to the Artalk team."}

artalk.log

qwqcode added a commit that referenced this issue Apr 30, 2024
@qwqcode qwqcode added the bug Something isn't working label Apr 30, 2024
@qwqcode
Copy link
Member

qwqcode commented May 9, 2024

你好,v2.8.6 刚刚发布了,应该修复了这个问题,感谢反馈!

@echs-top
Copy link
Author

echs-top commented May 9, 2024

你好,v2.8.6 刚刚发布了,应该修复了这个问题,感谢反馈!

v2.8.6这个问题已经解决,更新成功

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