Revert "parser: Don't toggle idle state outside of the worker"
Revert "parser: Don't toggle idle state outside of the worker"

This reverts commit 5a65ab7b5d78b1684d8c435d3bc0e94e8946abd2.
This causes the tests to fail intermitently since we now base ourselves
on the idle state, but this commit was causing the idle state to flicker
on and off, which creates a lot of small windows for the test to
consider the scan completed whenever the discoverer turns idle right
after scheduling a task for parsing, and before the parser picks up the
task

chouquette/medialibrary,chouquette/medialibrary,chouquette/medialibrary,chouquette/medialibrary