version handling improved. ATTENTION: minor changes to the low-level
(session and commands) API.