Skip to content

Commit 5f3afac

Browse files
committed
Revert "fix(frontend): add finalize guard to model fetch for cancellation cleanup"
This reverts commit c6acf72.
1 parent c6acf72 commit 5f3afac

1 file changed

Lines changed: 1 addition & 10 deletions

File tree

frontend/src/app/workspace/component/hugging-face/hugging-face.component.ts

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -360,16 +360,7 @@ export class HuggingFaceComponent extends FieldType<FieldTypeConfig> implements
360360
`${AppSettings.getApiEndpoint()}/huggingface/models?task=${encodeURIComponent(tag)}`,
361361
{ observe: "response" }
362362
)
363-
.pipe(
364-
takeUntil(this.destroy$),
365-
finalize(() => {
366-
// If takeUntil cancels before next/error fires, clear the in-flight
367-
// guard so a later instance re-fetches instead of polling forever.
368-
if (!allModelsByTag.has(tag) && !errorByTag.has(tag)) {
369-
inFlightByTag.delete(tag);
370-
}
371-
})
372-
)
363+
.pipe(takeUntil(this.destroy$))
373364
.subscribe({
374365
next: resp => {
375366
const models = resp.body ?? [];

0 commit comments

Comments
 (0)