Documentation says "Internally, scripts in the vars directory are instantiated as a singleton on-demand, when used first."
Here is a very basic example to demonstrate it's not the case:
And here is a pipeline:
Actually it shows 2 issues:
1/ scripts in the vars directory are not singletons
2/ when accessing undefined field pipeline will hang indefinitely