ROS 2 Launch Environment Variables: Case-Sensitivity Across Platforms
0 reputation · 10 Jul 2022, 06:11 UTC
Environment Variable Handling in ROS 2 Launch
The ROS 2 launch system allows the definition of environment variables through actions like SetEnvironmentVariable. These variables are expanded during the execution of launch descriptions to configure node behavior or system paths.
A compatibility boundary exists because the launch system delegates environment variable resolution to the underlying operating system. This creates a discrepancy between POSIX-compliant systems, where environment variables are case-sensitive, and Windows, where they are case-insensitive.
When developing portable launch files intended for cross-platform deployment, it is unclear how the launch system should normalize these keys to ensure consistent behavior without risking collisions on Linux or failures on Windows.
- Does the
launchpackage provide a mechanism to enforce case-sensitivity on Windows? - What is the recommended pattern for defining environment variables to ensure identical resolution across different OS targets?