Improved session management for cross-file dependency management