The Latin phrase "deus ex machina" has its origins in the conventions of Greek tragedy, with ancient Roman dramatists continuing the use of the device. It refers to situations in which a mechane (crane) was used to lower actors playing a god or gods onto the stage.
I know people have already started to post Harry Potter spoilers, but ever since Azkaban, I have always asserted the WORST POSSIBLE ENDING would be it turns out the WHOLE THING was a dream by a child locked under the cupboard under the stairs, and they discovered his fictional "life story" after he starved to death by his cruel parents. I saw this terrible something like this:
As the EMT zipped up the body bag, he handed me the books. The collection was motley; several spiral notebooks, a few standard black composition books, three old hardback accountant ledgers, and in the end, he was forced to scribble on paper napkins and strips of torn off wallpaper, which he numbered in sequence so he wouldn't lose his place. He had even made editing and small pictures in the margins. You could see the madness in his handwriting as the last strength trickled away. But he lived on, determined to live; to strive just a little longer to finish his only work. His immortality would be assured in his works as if he knew his fate was inevitable. Even though his body was no longer stiff with rigamortis, it took two people to pry open his bony arms to free the cardboard box all his works lay in.
Over the next few weeks, I tried to make sense of the story. He placed himself as the lead, starting almost two years before we were even aware the Dursleys had a second child hidden away. How he saw his cousin, which he renamed as "Dudley," was not the tortured boy we had come to know at the hospital, but a cruel extension of his aunt's hatred for her sister. We never learned why he grew up there, or how he survived that long, but we could tell from the story that he started writing around age 11. As his writing improved with practice, the story became more elaborate. How a child who barely ate enough to survive could come up with such compelling fantasies, we may never know. Even toward the end, when the story became more fantastic, his sense of mortality seemed to catch up to him as all his favorite characters died one by one. But he still remained in control, even creating laws and consequences in his universe that rivaled the most detailed of fantasy writers of our time.
His was the indeterminable voice of the human spirit. We carefully wove the story back into a book form, edited some parts that made things more understandable, separated it into seven volumes, and published it so that others may know how he saw his life as it could have been, and not as an abused child who had no hopes or dreams. It is becoming the standard reading for those who need to understand the thoughts of prisoners who have been locked away for years, barely alive, but still dreaming and being human. It is a favorite among social workers to understand the elaborate lies some abused children weave around themselves to lock out the horror of their day to day life.
You will never be forgotten, Harry Potter. May God rest his soul.