Some hint as to the "mechanics" is available on the commit log for the TaskChain module:
I tried to give summary explanations as we went along, but I will add a compiled list below:
(1) PHP 7.2 deprecates the each() function
Ever since PHP 4.0, which was released in 2000, PHP has had the "each()" function which allows you to loop through an array extracting the key and value for each item. Suddenly, in PHP 7.2 it was deprecated, meaning it will disappear completely soon, with a warning message such as you reported on May 28th. To fix this, I replaced the occurrences of this function with either a "foreach(...)" loop, or the use of the "key()" and "current()" functions.
(2) Moodle core replaced the "openpopup()" function
The TaskChain module evolved from the QuizPort module for Moodle <= 1.9, and as a result it used some outdated code to effect the popup window. This used to be handled by a Moodle core function called "openpopup()", but this disappeared, to be replaced a few Moodle versions later by another function with the same. The new function accepted arguments in a different format, and so was incompatible with the calls made to the old function. To work around this, the TaskChain module now opens popups using the "window.open()" function available in standard JavaScript.
(3) Missing strings from the TaskChain language pack
During testing, I discovered incidentally that there were a couple of missing strings for some lesser known output formats for Hot Potatoes JCloze. This didn't affect what you were doing, but I fixed them anyway.
That's it really. Three small issues, whose effect was multiplied because they appeared all at once.
One feature of Moodle is that it is constantly evolving, as are the technologies on which it relies, such as PHP, databases and web servers. As a result, the plugins cannot work forever just as they are, and from time to they need adjusting, as in the case of the TaskChain module.
An important part of open-source software is the community of users, and the communication tools available to everybody. As long as those are work well, as they did here, the software continues to improve and continues to help everybody.
Thank for you helping
and please continue to report strangeness where you come across it 
Kind regards,
Gordon