Even the most familiar spells can occasionally decide to behave like something found in the Restricted Section.
This time, the troublesome incantation was:
m update
Under the wrong circumstances, checking for a new Mediabot version could leave the command hanging instead of returning cleanly.
The asynchronous version checker had an awkward interaction between process creation, pipe handling and child-process monitoring.
In simple terms: Mediabot sent an owl to check the latest version… but there were two wizards waiting to receive the same owl.
That was never going to end elegantly.
The version-check worker has been cleaned up and made properly asynchronous.
The new implementation now uses:
IO::Async to monitor the worker lifecycle;The goal was not to redesign the update command, but to remove the race condition while preserving its existing behaviour.
The targeted tests passed, including the new regression coverage.
And more importantly, the entire Mediabot test suite was run after the final MB643 changes:
PASSED : 12871/12871
RC=0
12,871 tests. Zero failures.
Professor McGonagall may consider the paperwork complete.
The fix stays deliberately focused on the version-checking path.
No database schema change.
No command syntax change.
No unnecessary redesign.
Just a troublesome little piece of asynchronous magic put back under control.
You must be logged in to reply.