Every developer knows the demo effect. I'm sure it's common in other engineering disciplines as well and maybe even in other fields as well. The case is, that no matter how well prepared you are, how many tests you have ran and how perfectly everything worked on those times, when you show your work to others something unexpected will happen.
Despite thorough testing there can always be bugs in the code. And usually there is pressure to show some progress as early as possible. Management, customer or shareholders want to see things moving forward.
But the reason for everything failing can be external too, like network problems for example. Those you can't affect so you need to be prepared for everything.
Of course it's nice to show your work live. Prove it works. But sometimes you just can't afford to fail. So at least in those cases it's better to resort to pre-generated results or recording. And if you absolutely need to show the actual work in those situations it's important to set the expectations low enough.