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

fix:排队时,队列数量提示错误 #269

Closed
wants to merge 7 commits into from

Conversation

ElliotChina
Copy link
Contributor

目前设置了任务队列数量为3,提交第4个任务时候并不会提示开始排队,提交第5个任务时候会开始排队计数,且返回前面任务为1个。
应当在this.taskExecutor.submit执行之后再检查队列中的任务数量获取getQueue().size(),这样避免排队数量统计遗漏的错误。
修改后的结果为:设置了任务队列数量为3时,提交第4个任务时候提示还有1个任务等待,提交第5个任务时候提示前面任务为2个。

@ElliotChina
Copy link
Contributor Author

发现一些特定规律的prompt会出现无法正常通知进度和成功消息,经过测试,是midjourney会对prompt做一些简化,导致提交的prompt和返回的prompt不一致,从而发生无法匹配到任务队列中的任务最终无法推送通知,对2种情况进行了适配。

@ElliotChina
Copy link
Contributor Author

目前设置了任务队列数量为3,提交第4个任务时候并不会提示开始排队,提交第5个任务时候会开始排队计数,且返回前面任务为1个。 应当在this.taskExecutor.submit执行之后再检查队列中的任务数量获取getQueue().size(),这样避免排队数量统计遗漏的错误。 修改后的结果为:设置了任务队列数量为3时,提交第4个任务时候提示还有1个任务等待,提交第5个任务时候提示前面任务为2个。

修改后会带来另一个问题

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant