def session(self):
        # Cache session if not cached
        if not hasattr(self, "_session"):
            self._session = pavlovia.getCurrentSession()
        # Return cached session
        return self._session