mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-05-01 11:42:06 +00:00
feat(historyV2): create sythetic queue priority (#6336)
## Summary Create display priority based on execution success timestamps. Next up is displaying in progress prompts in the queue. ## Review Focus @DrJKL and I discussed logic and decided for history, execution success (when the prompt finishes) is the best way to assign priority. This does differ from existing cloud logic which uses execution start time. For prompt progress I intend to create a priority for them based on start time. ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-6336-feat-historyV2-create-sythetic-queue-priority-2996d73d365081ffa3a0f8071c178066) by [Unito](https://www.unito.io)
This commit is contained in:
@@ -233,12 +233,17 @@ export const historyV2Fixture: HistoryResponseV2 = {
|
||||
|
||||
/**
|
||||
* Expected V1 transformation of historyV2Fixture
|
||||
* Priority is now synthetic based on execution_success timestamp:
|
||||
* - complete-item-id: has timestamp → priority 1 (only one with timestamp)
|
||||
* - no-status-id: no status → priority 0
|
||||
* - no-meta-id: empty messages → priority 0
|
||||
* - multi-output-id: empty messages → priority 0
|
||||
*/
|
||||
export const expectedV1Fixture: HistoryTaskItem[] = [
|
||||
{
|
||||
taskType: 'History',
|
||||
prompt: [
|
||||
24,
|
||||
1,
|
||||
'complete-item-id',
|
||||
{},
|
||||
{
|
||||
@@ -295,7 +300,7 @@ export const expectedV1Fixture: HistoryTaskItem[] = [
|
||||
{
|
||||
taskType: 'History',
|
||||
prompt: [
|
||||
23,
|
||||
0,
|
||||
'no-status-id',
|
||||
{},
|
||||
{
|
||||
@@ -319,7 +324,7 @@ export const expectedV1Fixture: HistoryTaskItem[] = [
|
||||
{
|
||||
taskType: 'History',
|
||||
prompt: [
|
||||
22,
|
||||
0,
|
||||
'no-meta-id',
|
||||
{},
|
||||
{
|
||||
@@ -342,7 +347,7 @@ export const expectedV1Fixture: HistoryTaskItem[] = [
|
||||
{
|
||||
taskType: 'History',
|
||||
prompt: [
|
||||
21,
|
||||
0,
|
||||
'multi-output-id',
|
||||
{},
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user