ankitects / ankitects/anki

Backup dialog interferring with add-on's QueryOp

Open
#4,613 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
30.5k
Forks
3.2k
Avg merge
2d 8h
Merged PRs (30d)
72

Description

> Hi. I’m writing an add-on that generates audio files and uses an external Python script. Since Anki creates a new backup every 5 minutes and opens a modal window (“Creating backup”), the add-on window completely loses focus, making it impossible to cancel the queue even if I want to. And the best part is that the backup window just stays there indefinitely.
> I’m curious if there’s a way to pause backups while the add-on is running.
> 2026-03-14_00-041920×1080 592 KB

Originally reported on https://forums.ankiweb.net/t/pause-disable-backups-during-background-tasks/69151

The backup task is also run in a QueryOp with collection_executor. The task doesn't start until all scheduled tasks are done (due to max_workers=1), but progress.start() is called immediately before the task is scheduled.

Contributor guide

Open the contributing guide

Research direction

Start by tracing the backup task through QueryOp and collection_executor, paying attention to the timing of progress.start() and the single-worker scheduling described in the issue. Done should mean scheduled add-on work can remain usable while backups run, without the backup dialog indefinitely taking focus.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
desktop
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.